Skip to content

ResolveGroupingAnalytics Logical Resolution Rule

ResolveGroupingAnalytics is a logical resolution rule (Rule[LogicalPlan]).

ResolveGroupingAnalytics is part of Resolution batch of Logical Analyzer.

Creating Instance

ResolveGroupingAnalytics takes no arguments to be created.

Singleton Object

ResolveGroupingAnalytics is a Scala object which is a class that has exactly one instance. It is created lazily when it is referenced, like a lazy val.

Learn more in Tour of Scala.

ResolveGroupingAnalytics is created when:

  • Analyzer is requested for batches

Executing Rule

Rule
apply(
  plan: LogicalPlan): LogicalPlan

apply is part of the Rule abstraction.

apply resolves the following operators in the input LogicalPlan:

tryResolveHavingCondition

tryResolveHavingCondition(
  h: UnresolvedHaving): LogicalPlan

tryResolveHavingCondition...FIXME

constructAggregate

constructAggregate(
  selectedGroupByExprs: Seq[Seq[Expression]],
  groupByExprs: Seq[Expression],
  aggregationExprs: Seq[NamedExpression],
  child: LogicalPlan): LogicalPlan

constructAggregate...FIXME

constructExpand

constructExpand(
  selectedGroupByExprs: Seq[Seq[Expression]],
  child: LogicalPlan,
  groupByAliases: Seq[Alias],
  gid: Attribute): LogicalPlan

constructExpand...FIXME

hasGroupingFunction

hasGroupingFunction(
  e: Expression): Boolean

hasGroupingFunction holds true when there is either Grouping or GroupingID expression in the given Expression (tree).

In other words, the given Expression or its children are Grouping or GroupingID expressions.