Skip to main content

Module pg_query

Module pg_query 

Source
Expand description

pg_query backend.

Uses libpg_query (the real Postgres parser, exposed via FFI) so we get 100% PG syntax coverage including features that sqlparser-rs doesn’t yet support (ON DELETE SET NULL (col), MERGE, FETCH FIRST, lateral derived tables, …). The conversion is intentionally lossy – we only extract the slots the rest of the workspace cares about (CREATE TABLE columns, FROM tables, projections, WHERE, etc). Anything richer than that lands in StatementKind::Unknown { text } so downstream features still see the raw SQL.

Functions§

parse