30 open-source projects similar to kyleconroy/sqlc, ranked by how many features they have in common. Compare stars, activity and what each one does to find the best Sqlc alternative.
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
ihp is a type-safe web framework and full-stack application orchestrator designed for PostgreSQL. It functions as a server-side rendering framework and a type-safe ORM that automatically generates record types from SQL schemas to ensure compile-time query validation. The platform distinguishes itself by verifying routing, database queries, and templates at compile time to prevent runtime crashes. It implements real-time web interfaces using WebSockets for instant data synchronization and employs server-driven hypermedia for partial DOM patching. The framework covers a broad range of integrat
Drift is a type-safe SQL persistence library and relational mapper that provides a structured way to map database tables to classes and execute SQL queries with build-time validation. It functions as a type-safe query builder and a wrapper for SQLite and PostgreSQL, eliminating manual result set parsing by binding query outputs to native objects. The project distinguishes itself through a build-time code generation system that produces type-safe APIs and validates raw SQL statements against database versions before execution. It features reactive query streaming, which transforms SQL queries
sqlc is a code generation tool that compiles raw SQL queries into type-safe application code. By analyzing SQL statements against database schema definitions during the build process, it eliminates the need for manual data mapping and prevents runtime type errors. The project functions as a schema-aware generator that translates database column types into native language primitives. It distinguishes itself through a modular, plugin-based architecture that allows for the extension of the generation pipeline to support diverse programming languages and custom frameworks beyond its default capab
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
Squirrel is a Go database library and SQL query builder that provides a programmatic interface for constructing and executing SQL statements. It enables the creation of queries using a fluent interface to avoid manual string concatenation. The library functions as a SQL dialect generator, producing queries formatted for specific database engines by adjusting placeholders and syntax to match target requirements. This allows for the generation of SQL compatible with multiple different database environments. Beyond query construction, the project covers the execution of generated statements aga
Prisma is a database toolkit that provides a unified access layer for interacting with relational and document databases. It centers on a declarative schema modeling approach, where developers define their data structures in a human-readable language. This schema serves as the single source of truth, from which the toolkit automatically generates type-safe database clients that provide compile-time validation and editor autocomplete for all data operations. The project distinguishes itself through a high-performance, Rust-based query engine that handles query planning and connection pooling o
SpacetimeDB is a stateful, real-time database platform that executes application logic directly within the database engine. By unifying data storage and business logic, it allows developers to build applications where state transitions are processed through atomic, server-side functions. The platform maintains persistent connections to stream incremental updates to clients, ensuring that local caches remain synchronized with the server state at all times. The platform distinguishes itself by generating type-safe client interfaces directly from server-side schema definitions, ensuring consiste
Prisma is a type-safe database object-relational mapper that uses a declarative schema to map data models to relational and document databases. It provides a unified toolkit for data access, combining a database driver with tools for schema management and record manipulation. The project features a multi-database driver that standardizes interactions across PostgreSQL, MySQL, and MongoDB. It includes a system for tracking and applying structural schema migrations across different environments and a graphical user interface for browsing and editing database records. The system ensures data in
Gel is an object-relational database system that models data as a graph of interconnected objects. By utilizing a strongly typed schema, it enables complex relational queries and polymorphic data structures without the need for traditional join tables. The system integrates native vector storage and similarity search operators, allowing it to function as both a relational and a vector database for semantic data retrieval. The platform distinguishes itself through a comprehensive suite of developer-centric automation tools. It features a declarative migration system that tracks and versions sc
This toolkit provides an asynchronous interface for interacting with relational databases, offering a unified driver-agnostic layer for managing connection pools and executing transactions. It is designed to integrate with asynchronous runtimes, enabling non-blocking database operations while maintaining secure, encrypted communication between the application and the database server. The project distinguishes itself through its compile-time validation capabilities, which use procedural macros to inspect SQL syntax and parameter types against a live database schema during the build process. Th
SQLDelight is a Kotlin database library that validates SQL schema, statements, and migrations at compile time, generating type-safe Kotlin query functions from labeled SQL files. It treats SQL as the source of truth for database definitions, catching schema errors during the build process before they reach production. The library supports multiple database dialects including SQLite, MySQL, PostgreSQL, HSQL, and H2, and generates platform-specific code for Android, iOS, JVM, and JavaScript targets. It provides a platform-specific driver abstraction that handles database connectivity difference
Kysely is a TypeScript SQL query builder that provides a type-safe interface for constructing and executing database queries. It functions as a database layer that ensures schema compliance and prevents runtime errors by using a fluent interface and a programmable way to build complex SQL statements. The project features a type-safe database layer capable of inferring return types and aliases from SQL selections and joins. It also includes a SQL migration manager to track and apply schema changes across different environments to keep database versions synchronized. The toolkit covers relatio
This project is a database toolkit for Go that provides schema-to-object mapping, fluent query construction, and automated code generation. It functions as a framework for type-safe database access, enabling developers to interact with relational databases by generating models and interfaces directly from existing database schemas. The toolkit distinguishes itself through a workflow that parses hand-written SQL files to generate type-safe functions, allowing for the integration of custom SQL while maintaining consistent result mapping. It supports modular customization through a plugin-based
ShardingSphere is a distributed SQL database middleware that provides sharding, read-write splitting, and distributed transaction management for relational databases. It functions as a layer that intercepts SQL queries to distribute data across multiple physical database instances for horizontal scaling. The project is distinguished by its ability to operate as either a standalone transparent database proxy or via direct integration as a JDBC driver. It features a SQL dialect translator that parses queries into abstract syntax trees to convert syntax between different database engines, enabli
Calcite is a framework for parsing, optimizing, and translating SQL queries into relational algebra for execution across diverse data sources. It functions as a cross-source query engine, a SQL parsing library, and a relational algebra optimizer. The project provides a cost-based optimization engine that transforms logical query plans into efficient physical execution plans using pluggable rules. It utilizes translation adapters to convert standard SQL requests into the native formats of external databases and messaging systems, enabling data federation across heterogeneous storage systems.
MyBatis-Flex is an object-relational mapping framework for Java that extends MyBatis with a fluent API and automated CRUD operations. It provides a data access suite featuring an automatic CRUD data mapper, a type-safe SQL query builder, and a row-based query engine for manipulating records without predefined entity classes. The framework includes a multi-dialect SQL translator that converts generated syntax across different database engines, such as MySQL, PostgreSQL, and Oracle. It further distinguishes itself by offering annotation-free entity mapping using runtime reflection and naming co
OpenCode is a terminal-based development agent that automates software engineering tasks by integrating artificial intelligence directly into the command-line environment. It functions as an autonomous workflow orchestrator, capable of executing file operations, running shell commands, and applying code patches to complete complex development tasks without manual intervention. The tool distinguishes itself through its ability to index local codebases into vector embeddings, enabling semantic search and natural language queries across project files. It maintains session context through a local
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
xo is a tool for generating type-safe Go models and query execution code from SQL database schemas and queries. It functions as a multi-dialect SQL tool supporting PostgreSQL, MySQL, SQLite, Oracle, and Microsoft SQL Server to produce idiomatic source code. The project uses a template-based generation system, allowing the structure and logic of the generated database source code to be defined through customizable text templates. It also includes a database schema visualizer that analyzes table relationships and definitions to create visual diagrams and structured documentation. The tool's ca
This project is an educational blog and learning resource dedicated to the Rust programming language. It provides a collection of curated guides, technical articles, and structured learning paths designed to teach language fundamentals, concurrency, and systems programming. The repository distinguishes itself by offering practical implementation tutorials for complex systems. This includes detailed guides on compiler development—specifically translating source code into targets such as ARM64, x86_64, LLVM IR, and WebAssembly—as well as networking examples for building multithreaded chat serve
dbt-core is a command-line framework for transforming data within a warehouse using modular SQL and version control. It functions as a data transformation engine that enables users to define data structures and business logic through declarative configuration files, which the system then compiles into executable code. By managing complex data dependencies through a directed acyclic graph, it ensures that transformation tasks execute in the correct order while maintaining a manifest-driven state to track lineage and execution history. The project distinguishes itself through an adapter-based d
Valibot is a modular, type-safe schema library for validating and parsing structural data in TypeScript environments.
sqlboiler is a database-first ORM generator for Go that analyzes an existing database schema to produce strongly typed structures and query helpers. It functions as a schema-driven code generator, transforming database tables and relationships into executable Go source code. The project distinguishes itself through a type-safe query builder that uses chainable modifiers to construct SQL statements, eliminating the need for raw string concatenation. It utilizes customizable text templates to generate source code, allowing for the aliasing of schema entities and the creation of custom templates
Prisma1 is a TypeScript object-relational mapper and type-safe database client designed for interacting with relational databases. It functions as a system for declarative schema modeling, where database structures are defined in a single schema file that automatically synchronizes with the underlying database. The project provides a type-safe query builder that generates a custom client to ensure database queries match defined schema types at compile time. It also includes a database GUI administrator, providing a visual web interface for browsing, editing, and managing relational database r
Querydsl is a framework for the construction of type-safe queries. It uses a fluent API and annotation-based code generation to create mirror classes from domain models, enabling compile-time validation of database queries and removing the need for manual string concatenation. The project provides a unified query syntax that translates into specific dialects for multiple backends, including SQL, MongoDB, Lucene, and JDO. It supports advanced query capabilities such as common table expressions, window functions, geospatial operations, and complex nested subqueries. Beyond data retrieval, the
Ent is a statically typed entity framework for Go that models database structures as a graph of nodes and edges. It functions as a code generation engine that transforms schema definitions into type-safe database clients, query builders, and migration scripts. By representing data as interconnected entities, the framework enables intuitive traversal of complex relationships and ensures that database interactions remain consistent with the application model at compile time. The framework distinguishes itself through its graph-based approach to data modeling and its reliance on compile-time cod
This project is a production-ready boilerplate designed for building subscription-based web applications. It provides a foundational framework for managing user identity, persistent relational data, and recurring billing cycles within a unified development environment. The platform distinguishes itself by integrating secure authentication workflows with automated subscription management. It utilizes a schema-first approach to database interactions, ensuring data consistency through type-safe queries and versioned migrations. By incorporating native support for payment provider APIs, the syste
Blitz is a fullstack development framework extension for Next.js and a command line interface used to bootstrap project structures and orchestrate local development servers. It integrates frontend and backend logic into a single workflow to facilitate the creation of complete web applications. The framework employs a zero-API backend integration and a direct database access layer, allowing frontend components to connect to serverless functions and databases without manual API definitions. It features a schema-driven type generator that automatically creates TypeScript definitions by analyzing
Yup is a JavaScript schema validation library used to define data shapes and validate runtime values. It functions as an object schema validator and a data coercion engine, allowing developers to transform raw input values into desired types before performing validation checks. The library is distinguished by its support for dynamic schema validation, where rules can be adjusted at runtime based on sibling field values or external context. It also enables recursive data structuring for polymorphic fields and provides a system for extracting static TypeScript interfaces from runtime schema def