[ https://issues.apache.org/jira/browse/HIVE-15369?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Owen O'Malley closed HIVE-15369. -------------------------------- > Extend column pruner to account for residual filter expression in Join > operator > ------------------------------------------------------------------------------- > > Key: HIVE-15369 > URL: https://issues.apache.org/jira/browse/HIVE-15369 > Project: Hive > Issue Type: Bug > Components: Logical Optimizer > Affects Versions: 2.2.0 > Reporter: Jesus Camacho Rodriguez > Assignee: Jesus Camacho Rodriguez > Fix For: 2.2.0 > > Attachments: HIVE-15369.patch > > > Introduced by HIVE-15251. > We need to extend ColumnPruner logic to take into account residual filter > expressions in Join operator. Otherwise, query will fail at execution time. > Issue can be reproduced as follows: > {code:sql} > set hive.strict.checks.cartesian.product=false; > CREATE TABLE test1 (key INT, value INT, col_1 STRING); > INSERT INTO test1 VALUES (NULL, NULL, 'None'), (98, NULL, 'None'), > (99, 0, 'Alice'), (99, 2, 'Mat'), (100, 1, 'Bob'), (101, 2, 'Car'); > CREATE TABLE test2 (key INT, value INT, col_2 STRING); > INSERT INTO test2 VALUES (102, 2, 'Del'), (103, 2, 'Ema'), > (104, 3, 'Fli'), (105, NULL, 'None'); > -- Complex condition and column projection > EXPLAIN > SELECT col_1, col_2 > FROM test1 LEFT OUTER JOIN test2 > ON (test1.value=test2.value > OR test1.key=test2.key); > SELECT col_1, col_2 > FROM test1 LEFT OUTER JOIN test2 > ON (test1.value=test2.value > OR test1.key=test2.key); > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)