MCPcopy Create free account
hub / github.com/MaterializeInc/materialize / window_frame_bound_ast_to_expr

Function window_frame_bound_ast_to_expr

src/sql/src/plan/query.rs:6025–6037  ·  view source on GitHub ↗
(bound: &WindowFrameBound)

Source from the content-addressed store, hash-verified

6023}
6024
6025fn window_frame_bound_ast_to_expr(bound: &WindowFrameBound) -> mz_expr::WindowFrameBound {
6026 match bound {
6027 WindowFrameBound::CurrentRow => mz_expr::WindowFrameBound::CurrentRow,
6028 WindowFrameBound::Preceding(None) => mz_expr::WindowFrameBound::UnboundedPreceding,
6029 WindowFrameBound::Preceding(Some(offset)) => {
6030 mz_expr::WindowFrameBound::OffsetPreceding(*offset)
6031 }
6032 WindowFrameBound::Following(None) => mz_expr::WindowFrameBound::UnboundedFollowing,
6033 WindowFrameBound::Following(Some(offset)) => {
6034 mz_expr::WindowFrameBound::OffsetFollowing(*offset)
6035 }
6036 }
6037}
6038
6039pub fn scalar_type_from_sql(
6040 scx: &StatementContext,

Callers 1

plan_window_frameFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected