Skip to content

Commit

Permalink
Check the missingInput simply
Browse files Browse the repository at this point in the history
  • Loading branch information
watermen committed Mar 18, 2015
1 parent 3579003 commit 25766b9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Expand Up @@ -85,9 +85,8 @@ class CheckAnalysis {

cleaned.foreach(checkValidAggregateExpression)

case o if o.children.nonEmpty &&
!o.references.filter(_.name != "grouping__id").subsetOf(o.inputSet) =>
val missingAttributes = (o.references -- o.inputSet).map(_.prettyString).mkString(",")
case o if o.children.nonEmpty && o.missingInput.nonEmpty =>
val missingAttributes = o.missingInput.map(_.prettyString).mkString(",")
val input = o.inputSet.map(_.prettyString).mkString(",")

failAnalysis(s"resolved attributes $missingAttributes missing from $input")
Expand Down
Expand Up @@ -191,6 +191,8 @@ case class Expand(
val sizeInBytes = child.statistics.sizeInBytes * projections.length
Statistics(sizeInBytes = sizeInBytes)
}

override def missingInput = super.missingInput.filter(_.name != VirtualColumn.groupingIdName)
}

trait GroupingAnalytics extends UnaryNode {
Expand Down

0 comments on commit 25766b9

Please sign in to comment.