File tree Expand file tree Collapse file tree 3 files changed +7
-7
lines changed
catalyst/src/main/scala/org/apache/spark/sql/catalyst/plans
core/src/main/scala/org/apache/spark/sql/execution
hive/src/main/scala/org/apache/spark/sql/hive/execution Expand file tree Collapse file tree 3 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -444,10 +444,10 @@ object QueryPlan extends PredicateHelper {
444444 }
445445
446446 /** Normalize and reorder the expressions in the given sequence. */
447- def canonicalizeExprSeq ( exprSeq : Seq [Expression ], output : AttributeSeq ): Seq [Expression ] = {
448- if (exprSeq .nonEmpty) {
449- val normalizedExprs = QueryPlan . normalizeExprId(exprSeq .reduce(And ), output)
450- splitConjunctivePredicates(normalizedExprs )
447+ def normalizePredicates ( predicates : Seq [Expression ], output : AttributeSeq ): Seq [Expression ] = {
448+ if (predicates .nonEmpty) {
449+ val normalized = normalizeExprId(predicates .reduce(And ), output)
450+ splitConjunctivePredicates(normalized )
451451 } else {
452452 Nil
453453 }
Original file line number Diff line number Diff line change @@ -519,8 +519,8 @@ case class FileSourceScanExec(
519519 relation,
520520 output.map(QueryPlan .normalizeExprId(_, output)),
521521 requiredSchema,
522- QueryPlan .canonicalizeExprSeq (partitionFilters, output),
523- QueryPlan .canonicalizeExprSeq (dataFilters, output),
522+ QueryPlan .normalizePredicates (partitionFilters, output),
523+ QueryPlan .normalizePredicates (dataFilters, output),
524524 None )
525525 }
526526}
Original file line number Diff line number Diff line change @@ -206,7 +206,7 @@ case class HiveTableScanExec(
206206 HiveTableScanExec (
207207 requestedAttributes.map(QueryPlan .normalizeExprId(_, input)),
208208 relation.canonicalized.asInstanceOf [CatalogRelation ],
209- QueryPlan .canonicalizeExprSeq (partitionPruningPred, input))(sparkSession)
209+ QueryPlan .normalizePredicates (partitionPruningPred, input))(sparkSession)
210210 }
211211
212212 override def otherCopyArgs : Seq [AnyRef ] = Seq (sparkSession)
You can’t perform that action at this time.
0 commit comments