You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@impala.apache.org by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org> on 2026/08/05 08:24:26 UTC

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Csaba Ringhofer has uploaded this change for review. ( http://gerrit.cloudera.org:8080/24661


Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages: ORDER BY, GROUP BY, SELECT DISTINCT,
DISTINCT aggregate parameters, analytic PARTITION BY / ORDER BY, and set
operations (UNION/INTERSECT/EXCEPT).

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc), which emit a single uniform message:
  "<exprDesc> with type '<type>' is not supported."

supportsComparison() also excludes UUID, which is not comparable until its
builtins are implemented; UUID is now rejected consistently at these sites.
Existing complex/VARIANT test messages are updated to the unified wording.

This is a geometry-free refactor extracted from the addin GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 81 insertions(+), 81 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/61/24661/1
-- 
To view, visit http://gerrit.cloudera.org:8080/24661
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 1
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 3:

Build Successful 

https://jenkins.impala.io/job/gerrit-code-review-checks/23532/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 3
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Wed, 05 Aug 2026 08:52:34 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Hello Impala Public Jenkins, 

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24661

to look at the new patch set (#3).

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages, e.g.  ORDER BY, GROUP BY ...

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc), which emit a single uniform message:
  "<exprDesc> with type '<type>' is not supported."

This slightly changes some error messages.

supportsComparison() also excludes UUID, which is not comparable until its
builtins are implemented; UUID is now rejected consistently at these sites.
Existing complex/VARIANT test messages are updated to the unified wording.

This is a geometry-free refactor extracted from the adding GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 81 insertions(+), 81 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/61/24661/3
-- 
To view, visit http://gerrit.cloudera.org:8080/24661
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 3
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Csaba Ringhofer has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
File fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java:

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java@362
PS4, Line 362:       child.getType().throwIfNotComparable("DISTINCT aggregate parameter", child);
> I think that the lost info is not that important, the user should be able t
Started the tests as I got +2 from Peter and would like to to rebase my geometry patch once this is merged. If you would like this changed, I can do it in another patch.



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 16:29:43 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 7: Verified+1


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 7
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 20:52:23 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Peter Rozsa (Code Review)" <ge...@cloudera.org>.
Peter Rozsa has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 6: Code-Review+2


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 6
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 14:58:40 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 2:

Build Successful 

https://jenkins.impala.io/job/gerrit-code-review-checks/23531/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 2
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Wed, 05 Aug 2026 08:49:55 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Csaba Ringhofer has uploaded a new patch set (#2). ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages, e.g.  ORDER BY, GROUP BY ...

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc), which emit a single uniform message:
  "<exprDesc> with type '<type>' is not supported."

This slightly changes some error messages.

supportsComparison() also excludes UUID, which is not comparable until its
builtins are implemented; UUID is now rejected consistently at these sites.
Existing complex/VARIANT test messages are updated to the unified wording.

This is a geometry-free refactor extracted from the adding GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 81 insertions(+), 81 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/61/24661/2
-- 
To view, visit http://gerrit.cloudera.org:8080/24661
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 2
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 7: Code-Review+2


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 7
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 16:28:22 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Aleksandr Efimov (Code Review)" <ge...@cloudera.org>.
Aleksandr Efimov has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4:

(1 comment)

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
File fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java:

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java@362
PS4, Line 362:       child.getType().throwIfNotComparable("DISTINCT aggregate parameter", child);
> The old message also named the aggregate itself ("... in aggregate function
The parameter is enough here. No need for a follow-up patch from my side. Thanks.



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 18:11:04 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 2:

(1 comment)

gerrit-auto-critic failed. You can reproduce it locally using command:

  python3 bin/jenkins/critique-gerrit-review.py --dryrun

To run it, you might need a virtual env with Python3's venv installed.

http://gerrit.cloudera.org:8080/#/c/24661/2/fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
File fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java:

http://gerrit.cloudera.org:8080/#/c/24661/2/fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java@364
PS2, Line 364:         // implemented). Reject with a clear error rather than letting it reach (and crash)
line too long (91 > 90)



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 2
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Wed, 05 Aug 2026 08:30:52 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Aleksandr Efimov (Code Review)" <ge...@cloudera.org>.
Aleksandr Efimov has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4:

(3 comments)

Read through PS4. Checked that nothing is left asserting the replaced wording (grep over the tree finds none) and that the STRUCT claim in the SetOperationStmt comment holds - castToSetOpCompatibleTypes rejects containsStruct() before that loop. Three notes.

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
File fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java:

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java@362
PS4, Line 362:       child.getType().throwIfNotComparable("DISTINCT aggregate parameter", child);
The old message also named the aggregate itself ("... in aggregate function 'count(distinct v)'"), the new one stops at the parameter. With several distinct aggregates in one query that pointer was doing some work - keep it, or is the parameter enough on its own?


http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/catalog/Type.java
File fe/src/main/java/org/apache/impala/catalog/Type.java:

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/catalog/Type.java@284
PS4, Line 284:     return !isComplexOrVariantType() && !isUuid();
One thing that may be worth a line in the commit message: this branch is not reachable from SQL yet. SlotRef.analyze throws "Reading UUID columns is not yet supported." before any of these checks; casts to and from UUID are not registered (CastExpr line 126); the aggregate, analytic and grouping builtin generators skip UUID (four "TODO: Add UUID builtin support" guards in BuiltinsDb); and the grammar has UUID only as a type name, never as a literal. So I could not find a way to get a UUID-typed expression this far.

The message reads as a behaviour change ("UUID is now rejected consistently at these sites") where it is really groundwork for when reading lands - which also explains why no test covers it.


http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/catalog/Type.java@292
PS4, Line 292:    */
The single call site that passes null shows the cost of one shared template: SetOperationStmt now produces "UNION, EXCEPT and INTERSECT with type 'VARIANT' is not supported.", which reads as if the operations had a type. The previous wording was "UNION, EXCEPT and INTERSECT are not supported for VARIANT type." The other six sites read well, since they do name an expression.

So an overload without an Expr would want its own sentence rather than this one - something like "<what> is not supported for type '<type>'." - which also removes the null argument this thread is about.



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Tue, 25 Aug 2026 17:14:32 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 5:

Build Successful 

https://jenkins.impala.io/job/gerrit-code-review-checks/23964/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 5
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 14:52:31 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 6:

Build Successful 

https://jenkins.impala.io/job/gerrit-code-review-checks/23965/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 6
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 15:03:48 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Csaba Ringhofer has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4:

(2 comments)

http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
File fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java:

http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java@262
PS3, Line 262: are not supported as DISTIN
> no need to mention now as the function call to throwIfNotComparable shows i
Done


http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/catalog/Type.java
File fe/src/main/java/org/apache/impala/catalog/Type.java:

http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/catalog/Type.java@292
PS3, Line 292: 
> The call sites asking for an overload that takes the SQL representation of 
Added expr as parameter.
It could be even more compact if Expr would get a function like throwIfResultIsNotComparable(String prefix).



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Sat, 22 Aug 2026 17:55:25 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 1:

(1 comment)

gerrit-auto-critic failed. You can reproduce it locally using command:

  python3 bin/jenkins/critique-gerrit-review.py --dryrun

To run it, you might need a virtual env with Python3's venv installed.

http://gerrit.cloudera.org:8080/#/c/24661/1/fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
File fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java:

http://gerrit.cloudera.org:8080/#/c/24661/1/fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java@364
PS1, Line 364:         // implemented). Reject with a clear error rather than letting it reach (and crash)
line too long (91 > 90)



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 1
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Comment-Date: Wed, 05 Aug 2026 08:26:31 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Hello Balazs Hevele, Peter Rozsa, Impala Public Jenkins, 

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24661

to look at the new patch set (#4).

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages, e.g.  ORDER BY, GROUP BY ...

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc, expr), which emit a single uniform
message: "<exprDesc> '<expr>' with type '<type>' is not supported."

This slightly changes some error messages.

supportsComparison() also excludes UUID, which is not comparable until its
builtins are implemented; UUID is now rejected consistently at these sites.
Existing complex/VARIANT test messages are updated to the unified wording.

This is a geometry-free refactor extracted from the adding GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 80 insertions(+), 81 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/61/24661/4
-- 
To view, visit http://gerrit.cloudera.org:8080/24661
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4:

Build started: https://jenkins.impala.io/job/gerrit-verify-dryrun/13893/ DRY_RUN=true


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Sat, 22 Aug 2026 17:55:53 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Hello Balazs Hevele, Arnab Karmakar, Aleksandr Efimov, Peter Rozsa, Impala Public Jenkins, 

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24661

to look at the new patch set (#6).

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages, e.g.  ORDER BY, GROUP BY ...

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc), which emit a single uniform message:
  "<exprDesc> with type '<type>' is not supported."

This slightly changes some error messages. Existing complex/VARIANT test
messages are updated to the unified wording.

This is a geometry-free refactor extracted from the adding GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 74 insertions(+), 74 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/61/24661/6
-- 
To view, visit http://gerrit.cloudera.org:8080/24661
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 6
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 7:

Build started: https://jenkins.impala.io/job/gerrit-verify-dryrun/14010/ DRY_RUN=false


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 7
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 16:28:23 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Csaba Ringhofer has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 6:

(3 comments)

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
File fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java:

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java@362
PS4, Line 362:       child.getType().throwIfNotComparable("DISTINCT aggregate parameter", child);
> The old message also named the aggregate itself ("... in aggregate function
I think that the lost info is not that important, the user should be able to deduce the offending aggregate from the info we print. Can rewrite it if you disagree.


http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/catalog/Type.java
File fe/src/main/java/org/apache/impala/catalog/Type.java:

http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/catalog/Type.java@284
PS4, Line 284:   }
> One thing that may be worth a line in the commit message: this branch is no
In the meantime uuid added operator suppiort, so this can be removed.


http://gerrit.cloudera.org:8080/#/c/24661/4/fe/src/main/java/org/apache/impala/catalog/Type.java@292
PS4, Line 292:   public void throwIfNotComparable(String exprDesc, Expr expr) throws AnalysisException {
> The single call site that passes null shows the cost of one shared template
Replaced the single call site with a "handmade" exception.



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 6
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Thu, 10 Sep 2026 14:45:30 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Peter Rozsa (Code Review)" <ge...@cloudera.org>.
Peter Rozsa has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 3:

(2 comments)

http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
File fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java:

http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java@262
PS3, Line 262: (complex, VARIANT and UUID)
no need to mention now as the function call to throwIfNotComparable shows it


http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/catalog/Type.java
File fe/src/main/java/org/apache/impala/catalog/Type.java:

http://gerrit.cloudera.org:8080/#/c/24661/3/fe/src/main/java/org/apache/impala/catalog/Type.java@292
PS3, Line 292: throwIfNotComparable
The call sites asking for an overload that takes the SQL representation of the expression. Only "expr.getType().throwIfNotComparable("UNION, EXCEPT and INTERSECT")" uses it without string concats, maybe it's worth checking how it looks with a throwIfNotComparable(String exprDesc, String exprSql) implementation.



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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 3
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Mon, 17 Aug 2026 14:52:22 +0000
Gerrit-HasComments: Yes

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4:

Build Successful 

https://jenkins.impala.io/job/gerrit-code-review-checks/23716/ : Initial code review checks passed. Use gerrit-verify-dryrun-external or gerrit-verify-dryrun to run full precommit tests.


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Sat, 22 Aug 2026 18:12:53 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has posted comments on this change. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................


Patch Set 4: Verified+1


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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 4
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>
Gerrit-Comment-Date: Sat, 22 Aug 2026 22:50:19 +0000
Gerrit-HasComments: No

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Csaba Ringhofer (Code Review)" <ge...@cloudera.org>.
Hello Balazs Hevele, Arnab Karmakar, Aleksandr Efimov, Peter Rozsa, Impala Public Jenkins, 

I'd like you to reexamine a change. Please visit

    http://gerrit.cloudera.org:8080/24661

to look at the new patch set (#5).

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages, e.g.  ORDER BY, GROUP BY ...

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc), which emit a single uniform message:
  "<exprDesc> with type '<type>' is not supported."

This slightly changes some error messages. Existing complex/VARIANT test
messages are updated to the unified wording.

This is a geometry-free refactor extracted from the adding GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 76 insertions(+), 74 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/61/24661/5
-- 
To view, visit http://gerrit.cloudera.org:8080/24661
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 5
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>

[Impala-ASF-CR] IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Posted by "Impala Public Jenkins (Code Review)" <ge...@cloudera.org>.
Impala Public Jenkins has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/24661 )

Change subject: IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable
......................................................................

IMPALA-15247: Unify not-comparable type checks in Type.throwIfNotComparable

Several analysis checks independently rejected complex/VARIANT types with
their own ad-hoc error messages, e.g.  ORDER BY, GROUP BY ...

Consolidate them into Type.supportsComparison() and
Type.throwIfNotComparable(exprDesc), which emit a single uniform message:
  "<exprDesc> with type '<type>' is not supported."

This slightly changes some error messages. Existing complex/VARIANT test
messages are updated to the unified wording.

This is a geometry-free refactor extracted from the adding GEOMETRY type:
https://gerrit.cloudera.org/#/c/24534/

Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Reviewed-on: http://gerrit.cloudera.org:8080/24661
Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
M fe/src/main/java/org/apache/impala/analysis/AnalyticExpr.java
M fe/src/main/java/org/apache/impala/analysis/MultiAggregateInfo.java
M fe/src/main/java/org/apache/impala/analysis/QueryStmt.java
M fe/src/main/java/org/apache/impala/analysis/SelectStmt.java
M fe/src/main/java/org/apache/impala/analysis/SetOperationStmt.java
M fe/src/main/java/org/apache/impala/catalog/Type.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeExprsTest.java
M fe/src/test/java/org/apache/impala/analysis/AnalyzeStmtsTest.java
M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-variant.test
M testdata/workloads/functional-query/queries/QueryTest/nested-array-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-map-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/nested-struct-in-select-list.test
M testdata/workloads/functional-query/queries/QueryTest/sort-complex.test
M testdata/workloads/functional-query/queries/QueryTest/struct-in-select-list.test
14 files changed, 74 insertions(+), 74 deletions(-)

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

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

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: I2dc2c4579508cf1f8954ac251087c52f2eddf36a
Gerrit-Change-Number: 24661
Gerrit-PatchSet: 8
Gerrit-Owner: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Aleksandr Efimov <dz...@gmail.com>
Gerrit-Reviewer: Arnab Karmakar <ar...@gmail.com>
Gerrit-Reviewer: Balazs Hevele <bh...@cloudera.com>
Gerrit-Reviewer: Csaba Ringhofer <cs...@cloudera.com>
Gerrit-Reviewer: Impala Public Jenkins <im...@cloudera.com>
Gerrit-Reviewer: Peter Rozsa <pr...@cloudera.com>