We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f9d6a73 commit e38f264Copy full SHA for e38f264
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/Optimizer.scala
@@ -186,7 +186,8 @@ object ProjectCollapsing extends Rule[LogicalPlan] {
186
}
187
188
def apply(plan: LogicalPlan): LogicalPlan = plan transformUp {
189
- // We only collapse these two
+ // We only collapse these two Projects if the child Project's expressions are all
190
+ // deterministic.
191
case Project(projectList1, Project(projectList2, child))
192
if !hasNondeterministic(projectList2) =>
193
// Create a map of Aliases to their values from the child projection.
0 commit comments