[ https://issues.apache.org/jira/browse/IMPALA-6342?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Armstrong updated IMPALA-6342: ---------------------------------- Description: The following query returns a warning under decimal_v1. However, it returns an error when decimal_v2 is enabled. {code} with t1 as (select cast(11.11 as decimal(38,3)) as col1), t2 as (select cast(1.11 as decimal(38,37)) as col2) select * from t1 join t2 on (col1 = col2) {code} The problem is that the value in col1 can't be scaled up to a scale 37 without overflowing. This could be bad because the entire query fails under decimal_v2 if a single such value is encountered. {noformat was: The following query returns a warning under decimal_v1. However, it returns an error when decimal_v2 is enabled. {code} with t1 as (select cast(11.11 as decimal(38,3)) as col1), t2 as (select cast(1.11 as decimal(38,37)) as col2) select * from t1 join t2 on (col1 = col2) {code} The problem is that the value in col1 can't be scaled up to a scale 37 without overflowing. This could be bad because the entire query fails under decimal_v2 if a single such value is encountered. > Query can incorrectly fail when joining on a decimal column under decimal_v2 > ---------------------------------------------------------------------------- > > Key: IMPALA-6342 > URL: https://issues.apache.org/jira/browse/IMPALA-6342 > Project: IMPALA > Issue Type: Bug > Components: Backend > Reporter: Taras Bobrovytsky > Priority: Major > > The following query returns a warning under decimal_v1. However, it returns > an error when decimal_v2 is enabled. > {code} > with > t1 as (select cast(11.11 as decimal(38,3)) as col1), > t2 as (select cast(1.11 as decimal(38,37)) as col2) > select * from t1 join t2 on (col1 = col2) > {code} > The problem is that the value in col1 can't be scaled up to a scale 37 > without overflowing. This could be bad because the entire query fails under > decimal_v2 if a single such value is encountered. > {noformat -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-all-unsubscr...@impala.apache.org For additional commands, e-mail: issues-all-h...@impala.apache.org