Skip to main content

evaluate_constant_expr

Function evaluate_constant_expr 

Source
pub fn evaluate_constant_expr(
    expr: &Expression,
    registry: &FunctionRegistry,
) -> Value
Expand description

Evaluate a constant-only expression (literal or function call over literals) into a Value, using the function registry. Used by the CREATE DML write path to support expressions like DATE('2024-01-15'). Returns Value::Null for expressions that reference variables or otherwise cannot be folded without a row context.