Maksim Zhuravkov created IGNITE-18666:
-----------------------------------------

             Summary: Sql. Subqueries with invalid aggregates in subqueries are 
not rejected
                 Key: IGNITE-18666
                 URL: https://issues.apache.org/jira/browse/IGNITE-18666
             Project: Ignite
          Issue Type: Bug
          Components: sql
            Reporter: Maksim Zhuravkov
             Fix For: 3.0.0-beta2


The following queries are expected to fail but they return some results: 
{code:java}
# this will fail, because "i" is not an aggregate but the SUM(i1.i) turns this 
query into an aggregate
skipif ignite3
statement error
SELECT i, (SELECT SUM(i1.i)) FROM integers i1;

# PG: ERROR:  column "i1.i" must appear in the GROUP BY clause or be used in an 
aggregate function
skipif ignite3
statement error
SELECT i+1, (SELECT SUM(i1.i)) FROM integers i1;
{code}





--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to