You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2023/01/11 18:58:12 UTC
[GitHub] [spark] jchen5 commented on a diff in pull request #39375: [SPARK-36124][SQL] Support subqueries with correlation through UNION
jchen5 commented on code in PR #39375:
URL: https://github.com/apache/spark/pull/39375#discussion_r1067355121
##########
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/DecorrelateInnerQuery.scala:
##########
@@ -667,6 +720,24 @@ object DecorrelateInnerQuery extends PredicateHelper {
val newJoin = j.copy(left = newLeft, right = newRight, condition = newCondition)
(newJoin, newJoinCond, newOuterReferenceMap)
+ case u: Union =>
+ // First collect outer references from all children
+ val collectedChildOuterReferences = collectOuterReferencesInPlanTree(u)
Review Comment:
It's described with an example in the linked doc https://docs.google.com/document/d/11b9ClCF2jYGU7vU2suOT7LRswYkg6tZ8_6xJbvxfh2I/edit# - does that answer your question? I'll add the info to the comments as well.
--
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: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org