-
- Downloads
[SPARK-17806] [SQL] fix bug in join key rewritten in HashJoin
## What changes were proposed in this pull request? In HashJoin, we try to rewrite the join key as Long to improve the performance of finding a match. The rewriting part is not well tested, has a bug that could cause wrong result when there are at least three integral columns in the joining key also the total length of the key exceed 8 bytes. ## How was this patch tested? Added unit test to covering the rewriting with different number of columns and different data types. Manually test the reported case and confirmed that this PR fix the bug. Author: Davies Liu <davies@databricks.com> Closes #15390 from davies/rewrite_key.
Showing
- sql/core/src/main/scala/org/apache/spark/sql/execution/joins/HashJoin.scala 32 additions, 33 deletions...scala/org/apache/spark/sql/execution/joins/HashJoin.scala
- sql/core/src/test/scala/org/apache/spark/sql/execution/joins/BroadcastJoinSuite.scala 47 additions, 0 deletions...apache/spark/sql/execution/joins/BroadcastJoinSuite.scala
Please register or sign in to comment