Jet is a type-safe SQL builder for Go that generates code and automatically maps query results to data structures.
Jet addresses the problem of writing SQL queries safely in Go by eliminating string-based query construction and manual result mapping. It generates Go code from your database schema, allowing you to build queries using type-safe methods rather than concatenating SQL strings. The generated code includes table definitions and column references that the compiler can verify, catching errors at build time rather than runtime. Query results are automatically mapped to Go structs, removing the need for manual row scanning and type conversion.
Jet suits projects where type safety and compile-time verification matter more than runtime flexibility. It works well with teams that prefer catching errors early and value IDE code completion for database operations. The tool supports multiple databases including PostgreSQL, MySQL, MariaDB, CockroachDB, and SQLite, making it applicable across different database choices. Developers accustomed to query builders in other languages will recognize the approach, though Jet's code generation step distinguishes it from purely runtime-based solutions.
The project shows consistent maintenance with regular commits addressing bug fixes and feature additions. Pull requests receive timely review and feedback from maintainers. The codebase demonstrates attention to test coverage, with tests accompanying new functionality. Issues are actively triaged and responded to by the maintainers, indicating engagement with user needs and problems.