Skip to content

Commit

Permalink
fix: Fixed bug in left outer join
Browse files Browse the repository at this point in the history
All the records from the end of a DataFrame would go missing from a left outer join due to typo in code.
  • Loading branch information
jacobfi committed Dec 12, 2022
1 parent 1679bc3 commit 0504310
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ private[crossbow] object SortMergeJoin {
}
}

if (leftSet.nonEmpty && isLeftJoin) addCartesianProduct(leftSet.head until leftSet.size, Seq(-1))
if (leftSet.nonEmpty && isLeftJoin) addCartesianProduct(leftSet.head until leftKey.size, Seq(-1))
if (rightSet.nonEmpty && isRightJoin) addCartesianProduct(Seq(-1), rightSet.head until rightKey.size)

val leftFinal = left.slice(leftResult.toIndexedSeq)
Expand Down

0 comments on commit 0504310

Please sign in to comment.