Package org.apache.calcite.tools
Interface RelBuilder.AggCall
- Enclosing class:
RelBuilder
public static interface RelBuilder.AggCall
Information necessary to create a call to an aggregate function.
-
Method Summary
Modifier and TypeMethodDescriptionapproximate(boolean approximate) Returns a copy of this AggCall that may return approximate results ifapproximateis true.Returns a copy of this AggCall with a given alias.default RelBuilder.AggCalldistinct()Returns a copy of this AggCall that is distinct.distinct(boolean distinct) Returns a copy of this AggCall that is optionally distinct.Returns a copy of this AggCall that applies a filter before aggregating values.ignoreNulls(boolean ignoreNulls) Returns a copy of this AggCall that ignores nulls.over()Converts this aggregate call to a windowed aggregate call.preOperands(Iterable<? extends RexNode> preOperands) Returns a copy of this AggCall with the given pre-operands.default RelBuilder.AggCallpreOperands(RexNode... preOperands) Returns a copy of this AggCall that sorts its input values byorderKeysbefore aggregating, as in SQL'sWITHIN GROUPclause.default RelBuilder.AggCallReturns a copy of this AggCall that sorts its input values byorderKeysbefore aggregating, as in SQL'sWITHIN GROUPclause.Returns a copy of this AggCall that makes its input values unique bydistinctKeysbefore aggregating, as in SQL'sWITHIN DISTINCTclause.default RelBuilder.AggCallReturns a copy of this AggCall that makes its input values unique bydistinctKeysbefore aggregating, as in SQL'sWITHIN DISTINCTclause.
-
Method Details
-
getPosition
SqlParserPos getPosition() -
filter
Returns a copy of this AggCall that applies a filter before aggregating values. -
sort
Returns a copy of this AggCall that sorts its input values byorderKeysbefore aggregating, as in SQL'sWITHIN GROUPclause. -
sort
Returns a copy of this AggCall that sorts its input values byorderKeysbefore aggregating, as in SQL'sWITHIN GROUPclause. -
preOperands
Returns a copy of this AggCall with the given pre-operands.Pre-operands apply at the start of aggregation and are constant for the whole query. They do not reference input columns and are typically
RexLiteral. An example isSqlInternalOperators.LITERAL_AGG; most aggregate functions do not take pre-operands. -
preOperands
-
unique
Returns a copy of this AggCall that makes its input values unique bydistinctKeysbefore aggregating, as in SQL'sWITHIN DISTINCTclause. -
unique
Returns a copy of this AggCall that makes its input values unique bydistinctKeysbefore aggregating, as in SQL'sWITHIN DISTINCTclause. -
approximate
Returns a copy of this AggCall that may return approximate results ifapproximateis true. -
ignoreNulls
Returns a copy of this AggCall that ignores nulls. -
as
Returns a copy of this AggCall with a given alias. -
distinct
Returns a copy of this AggCall that is optionally distinct. -
distinct
Returns a copy of this AggCall that is distinct. -
over
RelBuilder.OverCall over()Converts this aggregate call to a windowed aggregate call.
-