Expand description
Lift a PostgreSQL parse tree into the internal Statement AST.
The facade exposes compilation while statement-family modules own
validation and lowering. Tree-shaped SELECT/DDL/expression lowering remains
in the private tree module, and PostgreSQL type interpretation remains
in the private types module.
Structs§
- Parsed
Regprocedure Name - Parser-normalized routine name and optional exact input-type signature used by
PostgreSQL’sregprocandregprocedureinput functions. - Parsed
Regtype Name - Parser-normalized type identity used by
PostgreSQL’sregtypeandregprocedureinput functions. Components retain the parser’s distinction between aliases such as unquotedinteger(normalized topg_catalog.int4) and a quoted type named"integer"; type modifiers are intentionally omitted because these aliases identify a base catalog type.
Functions§
- compile
- parse_
regobject_ name - Parse the dotted identifier strings consumed by
PostgreSQL’sreg*input functions. This followsSplitIdentifierString: surrounding component whitespace is ignored, quoted components collapse doubled quotes without case folding, unquoted components extend to a dot or whitespace and use ASCII case folding, and every component is clipped toPostgreSQL’s 63-byte identifier limit. - parse_
regprocedure_ name - Parse one routine-name string with either an omitted signature (
regproc) or an exact signature (regprocedure). The caller owns the soft-error and cross-database policy because the two SQL input functions intentionally differ from ordinary DDL. - parse_
regtype_ name - Parse exactly one
PostgreSQLtype-name string without accepting adjacent SQL expressions.Noneis the soft-failure shape used for inputs such as an empty string orSETOF integer; lexical and type-name syntax errors are retained for the caller. - plan_
only_ for_ test - Lower
DROP FUNCTION/DROP PROCEDURE. Each target arrives as anObjectWithArgs; the argument type list (when spelled) is preserved as a typed signature because routine identity includes(schema, name, argument types). - resolve_
deferred_ create_ foreign_ table - resolve_
deferred_ create_ table