[ https://issues.apache.org/jira/browse/HIVE-14351?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ashutosh Chauhan updated HIVE-14351: ------------------------------------ Resolution: Fixed Fix Version/s: 2.2.0 Status: Resolved (was: Patch Available) Pushed to master. Thanks, Ratandeep! > Minor improvement in genUnionPlan method > ---------------------------------------- > > Key: HIVE-14351 > URL: https://issues.apache.org/jira/browse/HIVE-14351 > Project: Hive > Issue Type: Improvement > Affects Versions: 2.1.0 > Reporter: Ratandeep Ratti > Assignee: Ratandeep Ratti > Fix For: 2.2.0 > > Attachments: HIVE-14351.patch > > > {{org.apache.hadoop.hive.ql.parse.SemanticAnalyzer#genUnionPlan}} method can > trip new users reading the code. > Specifically on line 8979 > {code} > HashMap<String, ColumnInfo> leftmap = leftRR.getFieldMap(leftalias); > HashMap<String, ColumnInfo> rightmap = rightRR.getFieldMap(rightalias); > {code} > These column maps are actually LinkedHashMaps and the code relies on this > fact when iterating the two union branches in order. > This was not clear immediately and left me wondering how is it that > traversal order is consistent. > I've updated the code with this simple fix. -- This message was sent by Atlassian JIRA (v6.3.4#6332)