Expand description
Physical expressions for window functions
Modulesยง
- bounded_
window_ ๐agg_ exec - Stream and channel implementations for window function expressions. The executor given here uses bounded memory (does not maintain all the input data seen so far), which makes it appropriate when processing infinite inputs.
- utils ๐
- window_
agg_ ๐exec - Stream and channel implementations for window function expressions.
Structsยง
- Bounded
Window AggExec - Window execution plan
- Plain
Aggregate Window Expr - A window expr that takes the form of an aggregate function.
- Standard
Window Expr - A window expr that takes the form of a [
StandardWindowFunctionExpr]. - Window
AggExec - Window execution plan
- WindowUDF
Expr - Implements [
StandardWindowFunctionExpr] forWindowUDF
Traitsยง
- Window
Expr - Common trait for window function implementations
Functionsยง
- calc_
requirements ๐ - create_
udwf_ window_ expr - Creates a
StandardWindowFunctionExprsuitable for a user defined window function - create_
window_ expr - Create a physical expression for window function
- get_
best_ fitting_ window - Constructs the best-fitting windowing operator (a
WindowAggExecor aBoundedWindowExec) for the giveninputaccording to the specifications ofwindow_exprsandphysical_partition_keys. Here, best-fitting means not requiring additional sorting and/or partitioning for the given input. - get_
ordered_ partition_ by_ indices - This function calculates the indices such that when partition by expressions reordered with the indices resulting expressions define a preset for existing ordering. For instance, if input is ordered by a, b, c and PARTITION BY b, a is used, this vector will be [1, 0]. It means that when we iterate b, a columns with the order [1, 0] resulting vector (a, b) is a preset of the existing ordering (a, b, c).
- get_
partition_ ๐by_ sort_ exprs - get_
window_ mode - Compares physical ordering (output ordering of the
inputoperator) withpartitionby_exprsandorderby_keysto decide whether existing ordering is sufficient to run the current window operator. - schema_
add_ window_ field - Build field from window function and add it into schema
- sort_
options_ ๐resolving_ constant - Generates sort option variations for a given expression.
- window_
equivalence_ ๐properties - window_
expr_ ๐from_ aggregate_ expr - Creates an appropriate
WindowExprbased on the window frame and