PG Raw Parse provides a low level wrapper around the PostgreSQL backend parser. These bindings, as well as some additional functionality are provided by libpg_query.
In addition to parsing, we provide mechanisms to traverse an AST, construct new ASTs, and transform ASTs. See the API docs for more details.
This library's API surface is primarily driven by the needs of PgDog. It is not intended to be a complete, one-size-fits-all solution to PostgreSQL ASTs. Contributions are welcome, but pull requests adding large and complex features are unlikely to be accepted unless they align with PgDog's needs. For a more general purpose library, consider pg_query.rs.
Licensed under either of these:
- Apache License, Version 2.0, (LICENSE-APACHE or https://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or https://opensource.org/licenses/MIT)