jchen5 commented on code in PR #40811:
URL: https://github.com/apache/spark/pull/40811#discussion_r1169400548
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/subquery.scala:
##########
@@ -581,7 +594,10 @@ object RewriteCorrelatedScalarSubquery extends
Rule[LogicalPlan] with AliasHelpe
currentChild.output :+ origOutput,
Join(currentChild, query, LeftOuter, conditions.reduceOption(And),
joinHint))
- if (resultWithZeroTups.isEmpty) {
+ if (Utils.isTesting) {
+ assert(mayHaveCountBug.isDefined)
+ }
+ if (resultWithZeroTups.isEmpty || !mayHaveCountBug.getOrElse(true)) {
Review Comment:
And this is the second main part of the fix.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]