You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remove parser dependency from DuckDB engine - use database validation only
DuckDB now uses a minimal pass-through parser instead of the TiDB parser.
All SQL parsing, validation, and type checking happens directly in the
DuckDB database via the analyzer. This ensures 100% compatibility with
DuckDB syntax without maintaining a separate parser.
Changes:
- Removed TiDB parser dependency from parse.go
- Parser now returns minimal TODO AST nodes
- Deleted convert.go (AST conversion not needed)
- Database handles all SQL validation via PREPARE/DESCRIBE
- Updated documentation to reflect database-only validation approach
Benefits:
- No shared parser with MySQL/Dolphin engine
- Perfect DuckDB syntax compatibility
- Simpler codebase with fewer dependencies
- All validation happens where it should: in the database
The analyzer is now solely responsible for:
- Parsing SQL via DuckDB's native parser
- Validating queries against the schema
- Extracting column and parameter type information
- Normalizing DuckDB types to sqlc types
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <[email protected]>
DuckDB is the only engine that doesn't parse SQL in Go. All SQL parsing, validation, and type checking happens directly in the DuckDB database. This ensures 100% compatibility with DuckDB's SQL syntax without needing to maintain a separate parser.
0 commit comments