dongjoon-hyun commented on a change in pull request #27562:
[SPARK-30811][SQL][2.4] CTE should not cause stack overflow when it refers to
non-existent table with same name
URL: https://github.com/apache/spark/pull/27562#discussion_r379032159
##########
File path:
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala
##########
@@ -215,8 +215,8 @@ class Analyzer(
}
def substituteCTE(plan: LogicalPlan, cteRelations: Seq[(String,
LogicalPlan)]): LogicalPlan = {
- plan resolveOperatorsDown {
- case u: UnresolvedRelation =>
+ plan resolveOperatorsUp {
Review comment:
Although I know this change is correct, could you make a unit test for this
change? Actually, for the current test case, line 219 covers it already.
----------------------------------------------------------------
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]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]