yanlin-Lynn commented on issue #1715: [CALCITE-3662] Generate wrong SQL when 
plan contains Project(Sort(Aggregate)) and aggregate field has no alias
URL: https://github.com/apache/calcite/pull/1715#issuecomment-571870272
 
 
   I add a test case in RelToSqlConverterTest, it seems to produce a correct sql
   ```
   @Test public void testGroupByWithLimitPlan() {
       String query = "SELECT sum(\"salary\") FROM \"employee\" group by 
\"gender\" limit 10";
       sql(query)
           .ok("SELECT SUM(\"salary\")\n"
               + "FROM \"foodmart\".\"employee\"\n"
               + "GROUP BY \"gender\"\n"
               + "FETCH NEXT 10 ROWS ONLY");
     }
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to