Expand description
Defines the FIRST_VALUE/LAST_VALUE aggregations.
Structsยง
- First
Primitive ๐Groups Accumulator - First
Value - First
Value Accumulator - Last
Value - Last
Value ๐Accumulator - Trivial
First Value Accumulator - This accumulator is used when there is no ordering specified for the
FIRST_VALUEaggregation. It simply returns the first value it sees according to the pre-existing ordering of the input data, and provides a fast path for this case without needing to maintain any ordering state. - Trivial
Last Value Accumulator - This accumulator is used when there is no ordering specified for the
LAST_VALUEaggregation. It simply updates the last value it sees according to the pre-existing ordering of the input data, and provides a fast path for this case without needing to maintain any ordering state.
Functionsยง
- convert_
to_ ๐sort_ cols - Combines array refs and their corresponding orderings to construct
SortColumns. - filter_
states_ ๐according_ to_ is_ set - Filters states according to the
is_setflag at the last column and returns the resulting states. - first_
value - Returns the first value in a group of values.
- first_
value_ udaf - AggregateFunction that returns a
AggregateUDFforFirstValue - last_
value - Returns the last value in a group of values.
- last_
value_ udaf - AggregateFunction that returns a
AggregateUDFforLastValue - validate_
is_ ๐set_ flags - Validates that
is_set flagsdo not contain NULL values.