mirror of
https://github.com/apache/impala.git
synced 2026-01-29 03:00:27 -05:00
The bug: It is generally incorrect to re-order joins across outer/semi joins. For example, an inner join following an outer join may reduce the cardinality, so placing the inner join before the outer join during join re-ordering would be incorrect because the outer join is cardinality preserving (on one or both sides). The same argument holds for semi joins. The fix: Place outer and semi joins at a fixed position in the plan based on where they appeared in the original query. Inner joins to the left/right of outer/semi joins are still re-ordered properly. Change-Id: Idae837097b9376473d7f8124eef69b51f612b210 Reviewed-on: http://gerrit.ent.cloudera.com:8080/1909 Reviewed-by: Alex Behm <alex.behm@cloudera.com> Tested-by: jenkins Reviewed-on: http://gerrit.ent.cloudera.com:8080/1922