Skip to content

tree-sitter-sql-polyglotA multi-dialect SQL grammar for tree-sitter

An ANSI SQL base plus 22 independently compiled dialect grammars, layered with tree-sitter's grammar(parent, overrides) composition.

What this is ​

The grammar restructures the upstream DerekStride/tree-sitter-sql "permissive" grammar into a strict ANSI SQL base plus dialect extensions. Each dialect compiles to its own <dialect>/src/parser.c and can be used independently. The README has the full dialect table and install instructions, and AGENTS.md covers the grammar architecture.

  • Usage, install/import snippets for Rust, Node.js, Python, Go, Swift, and CMake/C, plus how per-dialect lazy loading works in each.
  • Dialect coverage, generated on every CI run, with per-dialect scores, the inheritance tree and the full feature-by-dialect matrix.
  • Changelog, the release history.
  • Downloads, the parser build artifacts (grammar sources, bindings, queries) mirrored from the latest main.