sqlc
sqlc copied to clipboard
Generate type-safe code from SQL
First of all, I'm a huge fan of sqlc and I use it every single personal go project where I need database support. Good work 🙏 I noticed that you...
This fixes the issue mentioned in https://github.com/kyleconroy/sqlc/issues/1845
### Version 1.15.0 ### What happened? Running sqlc to generate go code results in an error: `error generating code: source error: 22:9: expected type, found '-' (and 10 more errors)`...
Column names are less restricted than Go struct field names, which should be proper Go identifiers. Hence, column names cannot be translated directly into field names. This commit tries to...
### Version 1.13.0 ### What happened? Hi. New user, evaluating sqlc for use. **What Happens:** We have some migrations/*.sql. When running `sqlc generate`, all the .sql in this folder are...
### Version 1.15.0 ### What happened? When I use `sqlc.arg(blah)` twice in the same query and no other parameters, I'd expect the generated query method to have a `blah int`...
### Version 1.9.0 ### What happened? [Playground](https://play.sqlc.dev/p/a9f29ced408d9060179a65845dafd1dbc20a264031ecb3f916d7ba2bfa2f7fdfl) Code generated doesn't include function parameters for against field. ### Relevant log output _No response_ ### Database schema _No response_ ### SQL queries...
Running :copyfrom with a uuid causes ERROR: incorrect binary data format (SQLSTATE 22P03) with PGX
### Version 1.12.0 ### What happened? A bug happened! ### Relevant log output ```shell ERROR: incorrect binary data format (SQLSTATE 22P03) ``` ### Database schema ```sql CREATE TABLE IF NOT...
### Version 1.15.0 - 1.23.0 ### What happened? The noted query produces an error: ``` query/query.sql:72:1: column reference "value" not found exit status 1 db/generate.go:3: running "go": exit status 1...
### Version 1.15.0 ### What happened? I wanted to add following query: ``` -- name: NextTask :one SELECT id FROM dt_tasks WHERE (execute_at IS NULL OR execute_at