maropu commented on a change in pull request #29104:
URL: https://github.com/apache/spark/pull/29104#discussion_r454745158
##########
File path:
sql/core/src/main/scala/org/apache/spark/sql/execution/joins/BroadcastNestedLoopJoinExec.scala
##########
@@ -205,6 +226,117 @@ case class BroadcastNestedLoopJoinExec(
}
}
+ case class NotInSubquerySingleColumnOptimizeParams(
+ buildSideHashSet: mutable.HashSet[AnyRef],
+ isNullExists: Boolean,
+ isBuildRowsEmpty: Boolean)
+
+ private def notInSubquerySingleColumnOptimizeEnabled: Boolean = {
+ if (SQLConf.get.notInSubquerySingleColumnOptimizeEnabled &&
right.output.length == 1) {
+ // buildSide must be single column
+ // and condition must be either of following pattern
+ // or(a=b,isnull(a=b))
+ // or(isnull(a=b),a=b)
+ condition.get match {
+ case _@Or(_@EqualTo(leftAttr: AttributeReference, rightAttr:
AttributeReference),
Review comment:
btw, could you follow the format in the other code? For example, we need
to a space between `@` and `EqualTo`.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]