tree-sitter for BigQuery's SQL
This project supports StandardSQL in BigQuery. You could try out the demo on Github Pages
Supported BigQuery SQL feature
-
Basic Literals/Expressions
-
Query Statement
-
DML Statements
-
DDL Statements
- CREATE syntax for TABLE/VIEW/MATERIALIZED_VIEW
- CREATE synteax for FUNCTION
- CREATE syntax for TABLE FUNCTION
- DELETE syntax for any
- ALTER sytnax for any
-
DCL Statements
-
Procedural Language
-
BigQuery ML
-
Pre-GA features
References
- ZetaSQL: https://github.com/google/zetasql/blob/master/docs/README.md
- Other SQL Projects :
Development
Running tests
npm install --also=dev
npm test
Debbuging
npm run parse <file.sql>
outputs a syntax tree