[ https://issues.apache.org/jira/browse/HIVE-1642?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12932744#action_12932744 ]
Namit Jain commented on HIVE-1642: ---------------------------------- ConditionalResolverCommonJoin // Iterate the sorted_set to get big/small table file size for (int index = 0; index < sortedList.size(); index++) { Long key = sortedList.get(index); int i = fileSizeList.indexOf(key); String alias = aliasList.get(i); if (index != (size - 1)) { smallTablesFileSizeSum += key.longValue(); } else { bigTableFileSize += key.longValue(); bigTableFileAlias = alias; } } The lines: int i = fileSizeList.indexOf(key); String alias = aliasList.get(i); are only needed in the 'else' block > Convert join queries to map-join based on size of table/row > ----------------------------------------------------------- > > Key: HIVE-1642 > URL: https://issues.apache.org/jira/browse/HIVE-1642 > Project: Hive > Issue Type: Improvement > Components: Query Processor > Reporter: Namit Jain > Assignee: Liyin Tang > Fix For: 0.7.0 > > Attachments: hive-1642_5.patch, hive-1642_6.patch, hive_1642_1.patch, > hive_1642_2.patch, hive_1642_4.patch > > > Based on the number of rows and size of each table, Hive should automatically > be able to convert a join into map-join. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.