[ 
https://issues.apache.org/jira/browse/IGNITE-18670?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Maksim Zhuravkov updated IGNITE-18670:
--------------------------------------
    Description: 
Currently we expect the query bellow to fail
{code:java}
SELECT 1 AS k, SUM(i) FROM integers GROUP BY k+1 ORDER BY 2;
{code}
But in https://issues.apache.org/jira/browse/IGNITE-18212 we decided that 
ignite's dialect of the SQL supports this behaviour.
Update test_group_by.test and mark the query as OK.


  was:
The following query is considered invalid by some SQL frontends since they 
decided that it is not legal to reference aliases in GROUP BY clause. 
We should decide whether to reject such query or not as of now it works.

{code:java}
SELECT 1 AS k, SUM(i) FROM integers GROUP BY k+1 ORDER BY 2;
{code}



> Sql. It is possible to reference aliases in GROUP BY clause.
> ------------------------------------------------------------
>
>                 Key: IGNITE-18670
>                 URL: https://issues.apache.org/jira/browse/IGNITE-18670
>             Project: Ignite
>          Issue Type: Bug
>          Components: sql
>            Reporter: Maksim Zhuravkov
>            Priority: Minor
>              Labels: calcite2-required, calcite3-required, ignite-3
>             Fix For: 3.0.0-beta2
>
>
> Currently we expect the query bellow to fail
> {code:java}
> SELECT 1 AS k, SUM(i) FROM integers GROUP BY k+1 ORDER BY 2;
> {code}
> But in https://issues.apache.org/jira/browse/IGNITE-18212 we decided that 
> ignite's dialect of the SQL supports this behaviour.
> Update test_group_by.test and mark the query as OK.



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

Reply via email to