[ 
https://issues.apache.org/jira/browse/HIVE-3891?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13590219#comment-13590219
 ] 

Vikram Dixit K commented on HIVE-3891:
--------------------------------------

Hi Namit,

Can you please create a review request. I see one issue in the 
AbstractSMBJoinProcessor. The 

{noformat}
String joinAlias =
      bigTablePosition == 0 ?
        joinCtx.getLeftAlias() : joinCtx.getRightAliases()[bigTablePosition - 
1];
{noformat}

The joinCtx.getRightAliases() array size would be at most 2 in case of joining 
against different keys. However the code that produces the bigTablePosition 
traverses all the tables. If the big table position comes up as 2 in a 
multi-way join, this code will cause an ArrayOutOfBounds exception. This needs 
to be addressed.

Thanks
Vikram.
                
> physical optimizer changes for auto sort-merge join
> ---------------------------------------------------
>
>                 Key: HIVE-3891
>                 URL: https://issues.apache.org/jira/browse/HIVE-3891
>             Project: Hive
>          Issue Type: Bug
>            Reporter: Namit Jain
>            Assignee: Namit Jain
>         Attachments: auto_sortmerge_join_1.q, auto_sortmerge_join_1.q.out, 
> hive.3891.1.patch, hive.3891.2.patch, hive.3891.3.patch, hive.3891.4.patch, 
> hive.3891.5.patch, hive.3891.6.patch, hive.3891.7.patch
>
>


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to