Impala Public Jenkins has submitted this change and it was merged. ( 
http://gerrit.cloudera.org:8080/25004 )

Change subject: IMPALA-15467: Fix Calcite IF DECIMAL return type
......................................................................

IMPALA-15467: Fix Calcite IF DECIMAL return type

Exclude IF's BOOLEAN condition from DECIMAL return-type inference,
fixing INVALID_TYPE for valid DECIMAL branches.

CalciteOptimizerTest adds testIfDecimalReturnTypeExcludesCondition
and testIfDoubleAndDecimalCaseControls. QueryTest/if-decimal covers
NULL branches, mixed DECIMAL types and scanned conditions. Run the
same SQL from TestExprs and TestCalcitePlanner; the latter forces
Calcite.

Testing: both Java tests passed; the baseline reproduces INVALID_TYPE.
Shared QueryTest and TestCalcitePlanner passed (60 SELECT profiles),
with codegen on/off and shared-suite rewrites on/off.

Change-Id: I3101917e02cae76c48c9d9aaf0d2913de00daffb
Assisted-by: gpt-6.1-sol
Reviewed-on: http://gerrit.cloudera.org:8080/25004
Reviewed-by: Impala Public Jenkins <[email protected]>
Tested-by: Impala Public Jenkins <[email protected]>
---
M 
java/calcite-planner/src/main/java/org/apache/impala/calcite/operators/CommonOperatorFunctions.java
M 
java/calcite-planner/src/test/java/org/apache/impala/calcite/service/CalciteOptimizerTest.java
A testdata/workloads/functional-query/queries/QueryTest/if-decimal.test
M tests/query_test/test_calcite_planner.py
M tests/query_test/test_exprs.py
5 files changed, 112 insertions(+), 1 deletion(-)

Approvals:
  Impala Public Jenkins: Looks good to me, approved; Verified

--
To view, visit http://gerrit.cloudera.org:8080/25004
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I3101917e02cae76c48c9d9aaf0d2913de00daffb
Gerrit-Change-Number: 25004
Gerrit-PatchSet: 6
Gerrit-Owner: Aleksandr Efimov <[email protected]>
Gerrit-Reviewer: Aleksandr Efimov <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Michael Smith <[email protected]>
Gerrit-Reviewer: Steve Carlin <[email protected]>
Gerrit-Reviewer: Zoltan Borok-Nagy <[email protected]>

Reply via email to