allisonwang-db commented on a change in pull request #33004:
URL: https://github.com/apache/spark/pull/33004#discussion_r655767117
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
##########
@@ -2377,14 +2375,14 @@ class Analyzer(override val catalogManager:
CatalogManager)
def apply(plan: LogicalPlan): LogicalPlan =
plan.resolveOperatorsUpWithPruning(
_.containsPattern(PLAN_EXPRESSION), ruleId) {
case j: LateralJoin if j.left.resolved =>
- resolveSubQueries(j, j.children)
+ resolveSubQueries(j)
Review comment:
LateralJoin node has `resolveChildren` overridden to use both
`left.output` and `right.plan.output` so that it can be used to resolve the
join conditions for LateralJoin. Maybe we can modify this method to condition
on whether right tree is resolved or not.
https://github.com/apache/spark/blob/6ca56b01dc53259a57d92a8755660bcfb3a12612/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans/logical/basicLogicalOperators.scala#L1455-L1469
--
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]