Module sql_ast::ast

source ·
Expand description

SQL Abstract Syntax Tree (AST) types

Structs§

  • SQL assignment foo = expr as used in SQLUpdate
  • SQL column definition
  • An optionally-named ColumnOption: [ CONSTRAINT <name> ] <column-option>.
  • A single CTE (used after WITH): alias [(col1, col2, ...)] AS ( query ) The names in the column list before AS, when specified, replace the names of the columns returned by the query. The parser does not validate that the number of columns in the query matches the number of columns in the query.
  • A function call
  • An identifier, decomposed into its value or character data and the quote style.
  • A name of a table, view, custom type, etc., possibly multi-part, i.e. db.schema.obj
  • SQL ORDER BY expression
  • The most complete variant of a SELECT query expression, optionally including WITH, UNION / other set operations, and ORDER BY.
  • A restricted variant of SELECT (without CTEs/ORDER BY), which may appear either as the only body item of an SQLQuery, or as an operand to a set operation like UNION.
  • Specifies the data processed by a window function, e.g. RANGE UNBOUNDED PRECEDING or ROWS BETWEEN 5 PRECEDING AND CURRENT ROW.
  • A window specification (i.e. OVER (PARTITION BY .. ORDER BY .. etc.))

Enums§