Skip to content

Commit 03c522e

Browse files
committed
Filter only
1 parent 597d6d7 commit 03c522e

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/optimizer/RewriteArithmeticFiltersOnIntOrLongColumn.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
package org.apache.spark.sql.catalyst.optimizer
1919

2020
import org.apache.spark.sql.catalyst.expressions._
21-
import org.apache.spark.sql.catalyst.plans.logical.LogicalPlan
21+
import org.apache.spark.sql.catalyst.plans.logical.{Filter, LogicalPlan}
2222
import org.apache.spark.sql.catalyst.rules.Rule
2323
import org.apache.spark.sql.types.{DataType, IntegerType, LongType}
2424

@@ -41,8 +41,8 @@ import org.apache.spark.sql.types.{DataType, IntegerType, LongType}
4141
*/
4242
object RewriteArithmeticFiltersOnIntOrLongColumn extends Rule[LogicalPlan] with PredicateHelper {
4343
def apply(plan: LogicalPlan): LogicalPlan = plan transform {
44-
case q: LogicalPlan =>
45-
q transformExpressionsUp {
44+
case f: Filter =>
45+
f transformExpressionsUp {
4646
case e @ BinaryComparison(left: BinaryArithmetic, right: Literal)
4747
if isDataTypeSafe(left.dataType) =>
4848
transformLeft(e, left, right)

0 commit comments

Comments
 (0)