Skip to main content

evaluate_window_functions

Function evaluate_window_functions 

Source
pub fn evaluate_window_functions(
    rows: &mut [(String, Value)],
    specs: &[WindowFuncSpec],
)
Expand description

Evaluate window functions over sorted, partitioned rows.

rows is the sorted result set. Each row is a (doc_id, serde_json::Value). The same rows are mutated in place with window columns appended to each document.

Unknown window function names must be rejected by the planner before reaching this dispatcher; an unrecognised name here is an internal bug and panics rather than silently dropping the projection.