Skip to content

Commit

Permalink
Update HiveStrategies.scala
Browse files Browse the repository at this point in the history
  • Loading branch information
YanTangZhai committed Dec 2, 2014
1 parent 6e643f8 commit e572b9a
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,10 @@ private[hive] trait HiveStrategies {
// Filter out all predicates that only deal with partition keys, these are given to the
// hive table scan operator to be used for partition pruning.
val partitionKeyIds = AttributeSet(relation.partitionKeys)
val (pruningPredicates, otherPredicates) = predicates.partition {
_.references.subsetOf(partitionKeyIds)
val (pruningPredicates, otherPredicates) = predicates.partition { x =>
x.references.baseSet != null &&
!x.references.baseSet.isEmpty &&
x.references.subsetOf(partitionKeyIds)
}

pruneFilterProject(
Expand Down

0 comments on commit e572b9a

Please sign in to comment.