Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
Description
Calcite SQL-to-rel translator cannot handle a sub-query inside an aggregate function. An example is SqlToRelConverterTest.testAggCaseInSubquery:
SELECT SUM( CASE WHEN deptno IN (SELECT deptno FROM dept) THEN 1 ELSE 0 END) FROM emp
Similar issue CALCITE-516 involves IN with constant list inside an aggregate function, which is treated similarly to a sub-query but is simpler.
Attachments
Issue Links
- depends upon
-
CALCITE-1045 Decorrelate sub-queries in Project and Join
- Reopened
- is related to
-
CALCITE-516 GROUP BY on a CASE expression containing IN predicate fails
- Closed
-
CALCITE-816 Represent sub-query as a RexNode
- Closed
- links to