drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sean Hsuan-Yi Chu (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (DRILL-2376) UNION ALL on Aggregates with GROUP BY returns incomplete results
Date Tue, 10 Mar 2015 17:12:39 GMT

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

Sean Hsuan-Yi Chu resolved DRILL-2376.
--------------------------------------
    Resolution: Fixed

Resolved in commit #: 0368adf0c

> UNION ALL on Aggregates with GROUP BY returns incomplete results
> ----------------------------------------------------------------
>
>                 Key: DRILL-2376
>                 URL: https://issues.apache.org/jira/browse/DRILL-2376
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Query Planning & Optimization
>    Affects Versions: 0.8.0
>            Reporter: Abhishek Girish
>            Assignee: Sean Hsuan-Yi Chu
>
> The following query returns incomplete results:
> {code:sql}
> select x
> from
> (SELECT Sum(ss_ext_sales_price) x
> FROM  store_sales
> UNION ALL
> SELECT Sum(cs_ext_sales_price) x
> FROM catalog_sales) tmp
> GROUP BY x;
> Results from Drill:
> +------------+
> |     x      |
> +------------+
> | 3658019159.35 |
> +------------+
> 1 row selected (3.474 seconds)
> Results from Postgres:
>        x       
> ---------------
>  5265207074.51
>  3658019159.35
> (2 rows)
> {code}
> Removing GROUP BY returns the right results:
> {code:sql}
> select x
> from
> (SELECT Sum(ss_ext_sales_price) x
> FROM  store_sales
> UNION ALL
> SELECT Sum(cs_ext_sales_price) x
> FROM catalog_sales) tmp;
> Results from Drill:
> +------------+
> |     x      |
> +------------+
> | 5265207074.51 |
> | 3658019159.35 |
> +------------+
> {code}



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

Mime
View raw message