Skip to content

SQL Conformance

Lanexio Parser implements SQL:2016 parsing with dialect support for PostgreSQL, MySQL, SQLite, and T-SQL. The conformance corpus spans 5,423 real-world SQL files across 28 SQL dialects sourced from the sqlfluff fixture set.

parseSql(bytes, { dialect }) accepts 'ansi', 'postgres', 'mysql', 'sqlite', or 'tsql'. The dialect controls quoting rules, identifier syntax, comment styles, and operator recognition. detectDialect() in the conformance harness routes each file to its declared dialect.

SQL is the broadest grammar surface in the parser, targeting 28 SQL dialects. The invariants — never-throw, well-formed, and lossless — hold across all 5,423 files. Conformance is measured as a per-dialect ratcheting ledger that can only rise. The current ledger tracks ~75% of dialect fixtures producing non-error trees, with an active program to reduce the remaining carve-outs.

This is an honest, transparent conformance model, not a hidden gap. Every dialect’s baseline is exact-count gated.

AxisResult
never-throw0 throws across 5,423 corpus files
well-formedcorpus WF = 0, dialect-aware
losslesscorpus lossless = 0, dialect-aware
conformance169/170 suite passing, ~75% per-dialect ledger