sqlc
sqlc is a compiler that produces type-safe code from SQL queries. Analyzing the written SQL statements, it creates interfaces that can be used in the application code. Go supports languages such as Kotlin, Python and TypeScript.
sqlc
100sqlc-dev · ORM & Database Tooling
- You write SQL queries and create corresponding type-safe code interfaces automatically.
- Using the plugin system for supported languages, you integrate the application code with SQL.
- You include database operations in the application layer by providing the type-safe.
- • High number of open issues (710)
- • NeutralHacker News
How We Went All In on sqlc/pgx for Postgres and Go
“Yep, I realised I needed to give plpgsql a shot when I started thinking, from first principles, about all the effort I was wasting. Not just machine cycles - the buffer copying, context switches, network switches, latency - but also, as I was working in Java at the time, there…”
- • NeutralHacker News
How We Went All In on sqlc/pgx for Postgres and Go
“I think I'm missing something, but I don't get sqlc. Let's say I want to "get a list of authors", so in sqlc I would write: -- name: ListAuthors :many SELECT * FROM authors ORDER BY name; and in Go I can then say `authors, err := queries.ListAuthors(ctx)`. This is cool. Now, if…”