[ https://issues.apache.org/jira/browse/HIVE-11335?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14636164#comment-14636164 ]
fatkun commented on HIVE-11335: ------------------------------- [~jcamachorodriguez] Could you take a look? > Multi-Join Inner Query producing incorrect results > -------------------------------------------------- > > Key: HIVE-11335 > URL: https://issues.apache.org/jira/browse/HIVE-11335 > Project: Hive > Issue Type: Bug > Components: Query Planning > Affects Versions: 1.1.0 > Environment: CDH5.4.0 > Reporter: fatkun > > test step > {code} > create table log (uid string, uid2 string); > insert into log values ('1', '1'); > create table user (uid string, name string); > insert into user values ('1', "test1"); > select b.name, c.name from log a > left outer join (select uid, name from user) b on (a.uid=b.uid) > left outer join user c on (a.uid2=c.uid); > {code} > return wrong result: > 1 test1 > It should be both return test1 > I try to find error, if I use this query, return right result.(join key > different) > {code} > select b.name, c.name from log a > left outer join (select uid, name from user) b on (a.uid=b.uid) > left outer join user c on (a.uid=c.uid); > {code} > The explain is different,Query1 only select one colum > {code} > b:user > TableScan > alias: user > Statistics: Num rows: 1 Data size: 7 Basic stats: COMPLETE Column > stats: NONE > Select Operator > expressions: uid (type: string) > outputColumnNames: _col0 > {code} > I think there is something wrong in ColumnPruner.But i cannot find it out. > It may relate HIVE-10996 -- This message was sent by Atlassian JIRA (v6.3.4#6332)