Open DanielHunte opened 2 days ago
CC: @pedroerp
@DanielHunte Could you also paste the Velox unit test of merge join you created here?
I think this PR addresses this issue (still under review):
https://github.com/facebookincubator/velox/pull/11068
Cc: @JkSelf
@DanielHunte Could you also paste the Velox unit test of merge join you created here?
Sure. I added it to the end of the description.
It seems https://github.com/facebookincubator/velox/pull/11068 can fix this issue. I will follow up to resolve @pedroerp's comments. Thanks.
Bug description
Full Outer Joins results are expected to have unmatched rows from either table with nulls for the other table's columns. There is a bug in Velox's implementation where when x rows (x >= 2) match on the equality clause (ex. t0 = u0) but don't pass the filter (ex. t0 > 4), for some reason x - 1 rows are still considered a match and therefore results in missing rows in the output. See the following example.
Nothing should match since nothing passes the filter. This query should produce the table:
However Velox thinks there is a match on 2 and produces the table:
2 | 2
is an extra row and2 | NULL
andNULL | 2
are missing rows.Here is the unit test I made within MergeJoinTest.cpp:
System information
Wrote unit test on my linux dev server.
Relevant logs
No response