awesome-repositories.com
Blog
MCP
awesome-repositories.com

Discover the best open-source repositories with AI-powered search.

ExploreCurated searchesOpen-source alternativesSelf-hosted softwareBlogSitemap
ProjectMCP serverAboutHow we rankPress
LegalPrivacyTerms
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
andialbrecht avatar

andialbrecht/sqlparse

0
View on GitHub↗

Sqlparse

sqlparse is a Python library for the programmatic analysis and manipulation of SQL statements. It provides a non-validating parser that breaks down SQL text into tokens and a utility to divide strings containing multiple queries into individual statements.

The project includes a code formatter that reorganizes SQL statements using consistent indentation and keyword casing. It also provides mechanisms for automating this formatting and linting process through version control hooks to maintain code consistency.

AI search

Explore more awesome repositories

Describe what you need in plain English — the AI ranks thousands of curated open-source projects by relevance.

Start searching with AI

Features

  • SQL Parsers - Provides a non-validating Python library for breaking down SQL statements into tokens for analysis.
  • SQL Formatting - Offers utilities for pretty-printing and beautifying SQL code via consistent indentation and casing.
  • SQL Formatters - Reorganizes SQL statements with consistent indentation and keyword casing to improve readability.
  • Script Splitting - Divides large strings of multiple SQL commands into individual statements for sequential execution.
  • SQL Statement Parsing - Identifies and groups SQL statements based on delimiters to split complex scripts into individual queries.
  • String Splitting - Dividing strings containing multiple SQL queries into separate statements while respecting nested parentheses and quotes.
  • SQL Analysis and Linting - Integrates formatting into commit hooks to ensure SQL code consistency through automated linting.
  • Formatting Automations - Provides integration for automatically cleaning and formatting SQL files via version control hooks.
  • Indentation Depth Tracking - Tracks nesting depth of SQL clauses to apply consistent leading whitespace and alignment.
  • Keyword Normalizations - Implements mapping of SQL keywords to a consistent casing format via a predefined dictionary.
  • Regular Expression-Based Parsing - Uses compiled regular expression patterns to categorize SQL keywords and operators during lexing.
  • String Tokenization - Provides a mechanism to break SQL strings into discrete tokens based on patterns for further analysis.
  • Token Grouping - Clusters tokens into nested groups to create a hierarchical representation of SQL queries.
  • SQL Parsers - Non-validating SQL parser for Python.
  • Text Processing - Provides a non-validating parser for SQL statements.
4,008 stars·728 forks·Python·BSD-3-Clause·28 views

Star history

Star history chart for andialbrecht/sqlparseStar history chart for andialbrecht/sqlparse

How this analysis was created: This summary and feature list are AI-generated from collected project material and can contain mistakes. Stars, license and language are imported from GitHub. Inclusion does not mean that we have tested or audited this project. Check the source documentation for any feature you depend on. Learn more on our About page.

Frequently asked questions

What does andialbrecht/sqlparse do?

sqlparse is a Python library for the programmatic analysis and manipulation of SQL statements. It provides a non-validating parser that breaks down SQL text into tokens and a utility to divide strings containing multiple queries into individual statements.

What are the main features of andialbrecht/sqlparse?

The main features of andialbrecht/sqlparse are: SQL Parsers, SQL Formatting, SQL Formatters, Script Splitting, SQL Statement Parsing, String Splitting, SQL Analysis and Linting, Formatting Automations.

Which projects share features with andialbrecht/sqlparse?

Projects with overlapping indexed features include: jdorn/sql-formatter — This project is a PHP library designed for parsing, beautifying, and syntax-highlighting SQL queries. It provides a… tobymao/sqlglot — sqlglot is a SQL parser and transpiler that represents queries as abstract syntax trees to enable structural analysis,… jooq/jooq — jOOQ is a type-safe SQL query builder for Java that generates code from live database schemas, enabling compile-time… sqlfluff/sqlfluff — SQLFluff is a multi-dialect SQL linter, formatter, and style guide enforcer. It functions as a parser and analyzer… analysis-tools-dev/static-analysis — This project is a comprehensive, curated directory of static analysis, linting, and security scanning utilities. It… jsqlparser/jsqlparser — JSqlParser is a Java library for SQL query parsing, converting raw SQL strings into a structured hierarchy of strongly…

Projects sharing features with Sqlparse

These projects share indexed features with Sqlparse. Shared tags can include platform or build tooling; verify the primary use case before treating a result as a replacement.
  • jdorn/sql-formatterjdorn avatar

    jdorn/sql-formatter

    3,857View on GitHub↗

    This project is a PHP library designed for parsing, beautifying, and syntax-highlighting SQL queries. It provides a set of utilities to improve the readability of database code, facilitate debugging, and assist in the maintenance of complex query structures. The library distinguishes itself by offering both aesthetic and functional processing capabilities. It can transform raw SQL strings into structured, indented formats for human review, or compress them by removing comments and unnecessary whitespace to optimize them for network transmission and logging. Additionally, it includes a syntax

    HTML
    View on GitHub↗3,857
  • tobymao/sqlglottobymao avatar

    tobymao/sqlglot

    9,336View on GitHub↗

    sqlglot is a SQL parser and transpiler that represents queries as abstract syntax trees to enable structural analysis, modification, and semantic transformation. It functions as a dialect translator and query optimizer, converting SQL code between different database engines and simplifying syntax trees through rule-based normalization. The project provides a framework for defining custom SQL dialects by overriding tokenizers, parsers, and generators. It includes a lineage analyzer to track data flow from source tables through complex queries to identify the origin of specific columns. Additi

    Python
    View on GitHub↗9,336
  • jooq/jooqjOOQ avatar

    jOOQ/jOOQ

    6,666View on GitHub↗

    jOOQ is a type-safe SQL query builder for Java that generates code from live database schemas, enabling compile-time validation of SQL syntax and data types. Its core identity is built around a fluent DSL that mirrors SQL structure, a code generator that maps tables, views, and routines to Java objects, and a multi-dialect engine that translates the same DSL into vendor-specific SQL for over 30 databases. The project also includes a SQL parser and transformer for refactoring or dialect conversion, reactive stream integration for non-blocking query execution, and a JDBC proxy diagnostics tool f

    Javacode-generatordatabasedb2
    View on GitHub↗6,666
  • sqlfluff/sqlfluffsqlfluff avatar

    sqlfluff/sqlfluff

    9,525View on GitHub↗

    SQLFluff is a multi-dialect SQL linter, formatter, and style guide enforcer. It functions as a parser and analyzer that converts SQL scripts into structured trees to validate syntax, identify logical components, and enforce consistent capitalization, aliasing, and layout conventions across various database dialects. The system is specifically designed to handle templated SQL, providing the ability to analyze, parse, and lint files containing macros or placeholders. It uses dummy-parameter rendering and source mapping to validate the style and correctness of dynamic code before it is rendered

    Pythonhacktoberfestpypisql
    View on GitHub↗9,525
Compare all 30 related projects→