Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
Impala 1.2.1
-
None
Description
Repro:
create table test_join_a(x integer, y integer); create table test_join_b(x integer, y integer); insert into test_join_a values(null, 1); insert into test_join_a values(null, 2); insert into test_join_b values(null, 1); insert into test_join_b values(null, 3); select * from test_join_a a left join test_join_b b on (a.x = b.x or (a.x is null and b.x is null)) and a.y = b.y; Result of query (incorrect): +------+---+------+------+ | x | y | x | y | +------+---+------+------+ | NULL | 2 | NULL | NULL | | NULL | 1 | NULL | NULL | +------+---+------+------+ Expected results: +------+---+------+------+ | x | y | x | y | +------+---+------+------+ | NULL | 2 | NULL | NULL | | NULL | 1 | NULL | 1 | +------+---+------+------+