General SQL Parser documentation¶
General SQL Parser (GSP) is an embeddable Java and .NET SDK for parsing, validating, analyzing, formatting, and rewriting SQL from multiple database systems. It runs inside your application and does not need a database connection to build a typed abstract syntax tree (AST), report syntax errors, or inspect SQL structure.
Choose the route that matches why you are here.
Install GSP Find a guide Explore solutions Try SQL Playground
Choose where to start¶
New to GSP¶
Use the Quick Start to install the Java or .NET SDK and run your first parser. Java developers can then follow the Java learning path; C# developers can use the .NET task and demo guide.
You already know the task¶
Open the guide finder to go directly to SQL validation, table and column extraction, formatting, AST rewriting, lineage, database dialects, or production guidance. Where runnable source is available, the guide links to the exact Java and .NET project on GitHub.
You are evaluating GSP for a product¶
Start with solutions and use cases to see where GSP fits in a SQL safety gateway, developer tool, data-governance platform, or migration pipeline. Then review dialect support and validation evidence for the SQL your system handles.
Build by outcome¶
Validate SQL before execution or deployment¶
Check vendor-specific syntax offline and return line, column, token, and statement details to an editor, CI job, API, ETL service, or SQL gateway.
Inspect tables, columns, and the AST¶
Turn SQL text into structured metadata for catalogs, dependency discovery, access review, query routing, and custom analysis.
Format or safely rewrite SQL¶
Pretty-print SQL for people, or use the AST modification workflow to enforce policy and regenerate a validated statement.
Trace column-level data lineage¶
Connect target columns to their sources across expressions, CTEs, views, ETL statements, and stored procedures.
Work with a specific SQL dialect¶
Confirm grammar coverage and keyword compatibility for Oracle, SQL Server, PostgreSQL, Snowflake, BigQuery, Teradata, and other supported systems.
Look up facts and verify behavior¶
- Reference — API, AST nodes, SQL dialects, configuration, release notes, concepts, and validation reports.
- Concepts and architecture — how vendor grammars, token streams, AST nodes, semantic analysis, and lineage fit together.
- Validation reports — measured results from real SQL projects and sample schemas, including documented gaps.
- Frequently asked questions — technical, licensing, and purchasing answers.
The public Maven and NuGet packages are trial builds. Review the licensing FAQ before production use, or visit Support & Community when you need help.