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

Aman Sinha updated DRILL-2329:
------------------------------
    Assignee: Abhishek Girish  (was: Jinfeng Ni)

> TPCDS query 95 and simplified variant fail to execute
> -----------------------------------------------------
>
>                 Key: DRILL-2329
>                 URL: https://issues.apache.org/jira/browse/DRILL-2329
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Query Planning & Optimization
>    Affects Versions: 0.8.0
>            Reporter: Abhishek Girish
>            Assignee: Abhishek Girish
>             Fix For: 1.2.0
>
>         Attachments: drillbit.log, query95_stream0_sf1.sql
>
>
> TPCDS query 95 (attached) fails to validate. 
> *A simplified variant of the query (may not have much semantics) that fails:*
> {code:sql}
> WITH abc AS
> (
>        SELECT *
>        FROM   web_sales)
> SELECT
>          Count(DISTINCT ws_order_number) AS a1 ,
>          Sum(ws_ext_ship_cost)           AS a2 
> FROM     web_sales ws 
> WHERE     ws.ws_ship_addr_sk = 1
> AND      ws.ws_web_site_sk = web_site_sk
> ORDER BY count(DISTINCT ws_order_number)
> LIMIT 100;
> {code}
> *Error:*
> Query failed: SqlValidatorException: Aggregate expression is illegal in ORDER 
> BY clause of non-aggregating SELECT



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to