Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
0.9.0-incubating
-
None
-
None
Description
Following query reproduces the problem:
SELECT ss_item_sk, ss_ticket_number, ss_customer_sk, sr_return_quantity FROM store_sales LEFT OUTER JOIN store_returns ON (store_returns.sr_item_sk = store_sales.ss_item_sk AND store_returns.sr_ticket_number = store_sales.ss_ticket_number), reason WHERE store_returns.sr_reason_sk = reason.r_reason_sk AND r_reason_desc = 'reason 28';
The Join graph given is:
(SS --> SR) – Reason gets transformed in to
(SS x Reason) --> SR
This is an invalid reordering.
A short term solution may be to split join graph on outer join.