Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
0.9.0
-
None
Description
The following query returns incomplete results:
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)
Removing GROUP BY returns the right results:
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 | +------------+
Attachments
Attachments
Issue Links
- depends upon
-
DRILL-2234 IOOB when streaming aggregate is on the left side of hash join
- Open
-
DRILL-2207 Fix Union All Operator
- Resolved
- is depended upon by
-
DRILL-2377 UNION ALL on Aggregates with GROUP BY returns null when column aliases don't match
- Closed
-
DRILL-2378 UNION ALL on Aggregates with GROUP BY and ORDER BY fails when column aliases don't match
- Closed
- relates to
-
DRILL-1977 Wrong result with aggregation on top of UNION ALL operator
- Closed
-
DRILL-2380 TPC-DS Query 33 and simplified variants return wrong results
- Closed
-
DRILL-2377 UNION ALL on Aggregates with GROUP BY returns null when column aliases don't match
- Closed
-
DRILL-2378 UNION ALL on Aggregates with GROUP BY and ORDER BY fails when column aliases don't match
- Closed
-
DRILL-2379 UNION ALL with ORDER BY fails when column aliases don't match
- Closed