cloud-fan commented on code in PR #51847: URL: https://github.com/apache/spark/pull/51847#discussion_r2321508947
########## sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala: ########## @@ -4281,6 +4282,29 @@ object RemoveTempResolvedColumn extends Rule[LogicalPlan] { } } +object ApplyLimitAll extends Rule[LogicalPlan] { + def applyLimitAllToPlan(plan: LogicalPlan, isInLimitAll: Boolean = false): LogicalPlan = { + plan match { + case la: LimitAll => + applyLimitAllToPlan(la.child, isInLimitAll = true) + case cteRef: CTERelationRef if isInLimitAll => + cteRef.copy(isUnlimitedRecursion = Some(true)) + // Allow-list for pushing down Limit All. + case _: Project | _: Filter | _: Join | _: Union | _: Offset | + _: BatchEvalPython | _: ArrowEvalPython | _: SubqueryAlias => Review Comment: ```suggestion _: BaseEvalPython => ``` -- 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-unsubscr...@spark.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org