Commit af71f54
feat: add Trino parser to monorepo (#27)
Add ANTLR4-based Trino SQL parser (formerly PrestoSQL) from trino-parser repository into the parser monorepo.
Changes:
- Add trino/ directory with grammar files (TrinoLexer.g4, TrinoParser.g4)
- Add Makefile with build and test targets following the pattern of other parsers
- Include 94 SQL test examples covering comprehensive Trino SQL features
- Update package name and import paths to github.com/bytebase/parser/trino
- Add trino to CI workflow to run tests automatically
- All 94 test cases passing
Test coverage includes:
- DDL statements (CREATE, ALTER, DROP for tables, views, schemas, roles, materialized views)
- DML statements (SELECT, INSERT, UPDATE, DELETE, MERGE)
- Query features (CTEs, window functions, aggregations, joins, subqueries)
- Transaction control (START TRANSACTION, COMMIT, ROLLBACK)
- Session management (SET SESSION, RESET SESSION, SET ROLE)
- Security (GRANT, REVOKE, DENY)
- Administrative commands (SHOW, DESCRIBE, ANALYZE, EXPLAIN)
- Trino-specific features (table functions, refresh materialized view, etc.)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude <[email protected]>1 parent e35c065 commit af71f54
File tree
106 files changed
+69975
-1
lines changed- .github/workflows
- trino
- examples
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
106 files changed
+69975
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
| 37 | + | |
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
0 commit comments