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 29c8166 commit 68b9fadCopy full SHA for 68b9fad
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/Optimizer.scala
@@ -94,8 +94,6 @@ object ColumnPruning extends Rule[LogicalPlan] {
94
object NullPropagation extends Rule[LogicalPlan] {
95
def apply(plan: LogicalPlan): LogicalPlan = plan transform {
96
case q: LogicalPlan => q transformExpressionsUp {
97
- // Skip redundant folding of literals.
98
- case l: Literal => l
99
case e @ Count(Literal(null, _)) => Literal(0, e.dataType)
100
case e @ Sum(Literal(c, _)) if(c == 0) => Literal(0, e.dataType)
101
case e @ Average(Literal(c, _)) if(c == 0) => Literal(0.0, e.dataType)
0 commit comments