Skip to main content

parse_select_expr

Function parse_select_expr 

Source
pub fn parse_select_expr(
    expr_str: &str,
) -> Result<(Expr, Option<Ident>), ParseError>
Expand description

Parse a single SQL expression string (optionally with an alias) into sqlparser expression AST.

This is intended for PySpark parity helpers like selectExpr and expr() where the input is a projection expression, not a full SQL statement.