[ https://issues.apache.org/jira/browse/HIVE-8558?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14180060#comment-14180060 ]
Ashutosh Chauhan commented on HIVE-8558: ---------------------------------------- [~vikram.dixit] ok for 0.14? > CBO: enable n-way joins after CBO join reordering > ------------------------------------------------- > > Key: HIVE-8558 > URL: https://issues.apache.org/jira/browse/HIVE-8558 > Project: Hive > Issue Type: Bug > Reporter: Harish Butani > Assignee: Harish Butani > Attachments: HIVE-8558.1.patch > > > With CBO, we disable n-way joins. But for consecutive tables we can safely > collapse into n-way joins. For e.g this is safe to collapse: > {code} > select p1.p_name, p2.p_name, p3.p_name from part p1 join part p2 on p1.p_name > = p2.p_name join part p3 on p3.p_name = p1.p_name; > {code} > whereas, we shouldn't reorder in this case: > {code} > select p1.p_name, p2.p_name, p3.p_name > from part p1 join part p2 on p1.p_name = p2.p_name join part p3 on p3.p_size > = p1.p_size and p3.p_size = p2.p_size join part p4 on p1.p_name = p4.p_name; > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)