uros-b commented on code in PR #58186: URL: https://github.com/apache/spark/pull/58186#discussion_r3842003915
########## sql/core/src/main/scala/org/apache/spark/sql/execution/subquery.scala: ########## @@ -125,7 +125,9 @@ case class InSubqueryExec( @transient private lazy val inSet = InSet(child, result.toSet) - override def nullable: Boolean = child.nullable + // A NULL in the subquery result makes a non-matching probe evaluate to NULL, so the left side's + // nullability alone understates it. See SPARK-58442. + override def nullable: Boolean = child.nullable || plan.output.exists(_.nullable) Review Comment: For InSubqueryExec.nullable - please be aware of possible conflicts with PR #58077, which modifies the same line with a broader implementation (CreateNamedStruct LHS field nullability + LEGACY_IN_SUBQUERY_NULLABILITY config). -- 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]
