Package org.apache.druid.sql.calcite.rel
Class Grouping
java.lang.Object
org.apache.druid.sql.calcite.rel.Grouping
Represents Druid's concept of a "group by": dimensions, aggregations, post-aggregations, and 'having' filters. This
is always something that can be handled by a groupBy query, and in some cases, it may be handleable by a timeseries
or topN query type as well.
This corresponds to a Calcite Aggregate + optional Filter + optional Project.
It does not include sorting, limiting, or post-sorting projections: for this, see the
Sorting class.-
Method Summary
Modifier and TypeMethodDescriptionapplyProject(PlannerContext plannerContext, org.apache.calcite.rel.core.Project project) Applies a post-grouping projection.static Groupingcreate(List<DimensionExpression> dimensions, Subtotals subtotals, List<Aggregation> aggregations, DimFilter havingFilter, RowSignature outputRowSignature) booleanbooleaninthashCode()
-
Method Details
-
create
public static Grouping create(List<DimensionExpression> dimensions, Subtotals subtotals, List<Aggregation> aggregations, @Nullable DimFilter havingFilter, RowSignature outputRowSignature) -
getDimensions
-
getSubtotals
-
getAggregations
-
getHavingFilter
-
getDimensionSpecs
-
getAggregatorFactories
-
getPostAggregators
-
getOutputRowSignature
-
hasGroupingDimensionsDropped
public boolean hasGroupingDimensionsDropped() -
applyProject
public Grouping applyProject(PlannerContext plannerContext, org.apache.calcite.rel.core.Project project) Applies a post-grouping projection.- See Also:
-
which uses this
-
equals
-
hashCode
public int hashCode()
-