Copy disabled (too large)
Download .txt
Showing preview only (14,378K chars total). Download the full file to get everything.
Repository: sqlc-dev/sqlc
Branch: main
Commit: ce83d3fe9f59
Files: 6671
Total size: 12.3 MB
Directory structure:
gitextract_4y3p3xpd/
├── .github/
│ ├── ISSUE_TEMPLATE/
│ │ ├── BUG_REPORT.yml
│ │ └── FEATURE_REQUEST.yml
│ ├── dependabot.yml
│ └── workflows/
│ ├── buf.yml
│ ├── build.yml
│ ├── ci-kotlin.yml
│ ├── ci-python.yml
│ ├── ci-typescript.yml
│ ├── ci.yml
│ └── gen.yml
├── .gitignore
├── .readthedocs.yaml
├── .vscode/
│ └── settings.json
├── CLAUDE.md
├── Dockerfile
├── LICENSE
├── Makefile
├── README.md
├── buf.gen.yaml
├── buf.work.yaml
├── cliff.toml
├── cmd/
│ ├── sqlc/
│ │ └── main.go
│ ├── sqlc-gen-json/
│ │ └── main.go
│ └── sqlc-test-setup/
│ └── main.go
├── devenv.nix
├── devenv.yaml
├── docker-compose.yml
├── docs/
│ ├── .gitignore
│ ├── Makefile
│ ├── _static/
│ │ └── customize.css
│ ├── _templates/
│ │ ├── breadcrumbs.html
│ │ └── layout.html
│ ├── conf.py
│ ├── guides/
│ │ ├── development.md
│ │ ├── migrating-off-hosted-managed-databases.md
│ │ ├── migrating-to-sqlc-gen-kotlin.md
│ │ ├── migrating-to-sqlc-gen-python.md
│ │ ├── plugins.md
│ │ ├── privacy.md
│ │ └── using-go-and-pgx.rst
│ ├── howto/
│ │ ├── ci-cd.md
│ │ ├── ddl.md
│ │ ├── delete.md
│ │ ├── embedding.md
│ │ ├── generate.md
│ │ ├── insert.md
│ │ ├── managed-databases.md
│ │ ├── named_parameters.md
│ │ ├── overrides.md
│ │ ├── prepared_query.md
│ │ ├── push.md
│ │ ├── query_count.md
│ │ ├── rename.md
│ │ ├── select.md
│ │ ├── structs.md
│ │ ├── transactions.md
│ │ ├── update.md
│ │ ├── verify.md
│ │ └── vet.md
│ ├── index.rst
│ ├── overview/
│ │ └── install.md
│ ├── reference/
│ │ ├── changelog.md
│ │ ├── cli.md
│ │ ├── config.md
│ │ ├── datatypes.md
│ │ ├── environment-variables.md
│ │ ├── language-support.rst
│ │ ├── macros.md
│ │ └── query-annotations.md
│ ├── requirements.txt
│ └── tutorials/
│ ├── getting-started-mysql.md
│ ├── getting-started-postgresql.md
│ └── getting-started-sqlite.md
├── examples/
│ ├── authors/
│ │ ├── mysql/
│ │ │ ├── db.go
│ │ │ ├── db_test.go
│ │ │ ├── models.go
│ │ │ ├── query.sql
│ │ │ ├── query.sql.go
│ │ │ └── schema.sql
│ │ ├── postgresql/
│ │ │ ├── db.go
│ │ │ ├── db_test.go
│ │ │ ├── models.go
│ │ │ ├── query.sql
│ │ │ ├── query.sql.go
│ │ │ └── schema.sql
│ │ ├── sqlc.yaml
│ │ └── sqlite/
│ │ ├── db.go
│ │ ├── db_test.go
│ │ ├── models.go
│ │ ├── query.sql
│ │ ├── query.sql.go
│ │ └── schema.sql
│ ├── batch/
│ │ ├── postgresql/
│ │ │ ├── batch.go
│ │ │ ├── db.go
│ │ │ ├── db_test.go
│ │ │ ├── models.go
│ │ │ ├── querier.go
│ │ │ ├── query.sql
│ │ │ ├── query.sql.go
│ │ │ └── schema.sql
│ │ └── sqlc.json
│ ├── booktest/
│ │ ├── mysql/
│ │ │ ├── db.go
│ │ │ ├── db_test.go
│ │ │ ├── models.go
│ │ │ ├── query.sql
│ │ │ ├── query.sql.go
│ │ │ └── schema.sql
│ │ ├── postgresql/
│ │ │ ├── db.go
│ │ │ ├── db_test.go
│ │ │ ├── models.go
│ │ │ ├── query.sql
│ │ │ ├── query.sql.go
│ │ │ └── schema.sql
│ │ ├── sqlc.json
│ │ └── sqlite/
│ │ ├── db.go
│ │ ├── db_test.go
│ │ ├── models.go
│ │ ├── query.sql
│ │ ├── query.sql.go
│ │ └── schema.sql
│ ├── jets/
│ │ ├── README.md
│ │ ├── postgresql/
│ │ │ ├── db.go
│ │ │ ├── models.go
│ │ │ ├── query-building.sql
│ │ │ ├── query-building.sql.go
│ │ │ └── schema.sql
│ │ └── sqlc.json
│ └── ondeck/
│ ├── mysql/
│ │ ├── city.sql.go
│ │ ├── db.go
│ │ ├── db_test.go
│ │ ├── models.go
│ │ ├── querier.go
│ │ ├── query/
│ │ │ ├── city.sql
│ │ │ └── venue.sql
│ │ ├── schema/
│ │ │ ├── 0001_city.sql
│ │ │ ├── 0002_venue.sql
│ │ │ └── 0003_add_column.sql
│ │ └── venue.sql.go
│ ├── postgresql/
│ │ ├── city.sql.go
│ │ ├── db.go
│ │ ├── db_test.go
│ │ ├── models.go
│ │ ├── querier.go
│ │ ├── query/
│ │ │ ├── city.sql
│ │ │ └── venue.sql
│ │ ├── schema/
│ │ │ ├── 0001_city.sql
│ │ │ ├── 0002_venue.sql
│ │ │ └── 0003_add_column.sql
│ │ └── venue.sql.go
│ ├── sqlc.json
│ └── sqlite/
│ ├── city.sql.go
│ ├── db.go
│ ├── db_test.go
│ ├── models.go
│ ├── querier.go
│ ├── query/
│ │ ├── city.sql
│ │ └── venue.sql
│ ├── schema/
│ │ ├── 0001_city.sql
│ │ ├── 0002_venue.sql
│ │ └── 0003_add_column.sql
│ └── venue.sql.go
├── go.mod
├── go.sum
├── internal/
│ ├── analysis/
│ │ ├── analysis.pb.go
│ │ └── analysis_vtproto.pb.go
│ ├── analyzer/
│ │ └── analyzer.go
│ ├── bundler/
│ │ ├── multipart.go
│ │ └── upload.go
│ ├── cache/
│ │ └── cache.go
│ ├── cmd/
│ │ ├── cmd.go
│ │ ├── createdb.go
│ │ ├── diff.go
│ │ ├── generate.go
│ │ ├── options.go
│ │ ├── parse.go
│ │ ├── process.go
│ │ ├── push.go
│ │ ├── shim.go
│ │ ├── verify.go
│ │ ├── vet.go
│ │ └── vet_sqlite.go
│ ├── codegen/
│ │ ├── golang/
│ │ │ ├── driver.go
│ │ │ ├── enum.go
│ │ │ ├── field.go
│ │ │ ├── gen.go
│ │ │ ├── go_type.go
│ │ │ ├── imports.go
│ │ │ ├── mysql_type.go
│ │ │ ├── opts/
│ │ │ │ ├── enum.go
│ │ │ │ ├── go_type.go
│ │ │ │ ├── options.go
│ │ │ │ ├── override.go
│ │ │ │ ├── override_test.go
│ │ │ │ └── shim.go
│ │ │ ├── postgresql_type.go
│ │ │ ├── query.go
│ │ │ ├── reserved.go
│ │ │ ├── result.go
│ │ │ ├── result_test.go
│ │ │ ├── sqlite_type.go
│ │ │ ├── struct.go
│ │ │ ├── template.go
│ │ │ └── templates/
│ │ │ ├── go-sql-driver-mysql/
│ │ │ │ └── copyfromCopy.tmpl
│ │ │ ├── pgx/
│ │ │ │ ├── batchCode.tmpl
│ │ │ │ ├── copyfromCopy.tmpl
│ │ │ │ ├── dbCode.tmpl
│ │ │ │ ├── interfaceCode.tmpl
│ │ │ │ └── queryCode.tmpl
│ │ │ ├── stdlib/
│ │ │ │ ├── dbCode.tmpl
│ │ │ │ ├── interfaceCode.tmpl
│ │ │ │ └── queryCode.tmpl
│ │ │ └── template.tmpl
│ │ ├── json/
│ │ │ ├── gen.go
│ │ │ └── opts.go
│ │ └── sdk/
│ │ ├── sdk.go
│ │ ├── utils.go
│ │ └── utils_test.go
│ ├── compiler/
│ │ ├── analyze.go
│ │ ├── compat.go
│ │ ├── compile.go
│ │ ├── engine.go
│ │ ├── expand.go
│ │ ├── find_params.go
│ │ ├── output_columns.go
│ │ ├── parse.go
│ │ ├── query.go
│ │ ├── query_catalog.go
│ │ ├── resolve.go
│ │ ├── result.go
│ │ ├── selector.go
│ │ ├── selector_test.go
│ │ └── to_column.go
│ ├── config/
│ │ ├── config.go
│ │ ├── config_test.go
│ │ ├── convert/
│ │ │ ├── convert.go
│ │ │ └── convert_test.go
│ │ ├── env.go
│ │ ├── v_one.go
│ │ ├── v_one.json
│ │ ├── v_two.go
│ │ ├── v_two.json
│ │ └── validate.go
│ ├── constants/
│ │ └── query.go
│ ├── dbmanager/
│ │ └── client.go
│ ├── debug/
│ │ └── dump.go
│ ├── endtoend/
│ │ ├── CLAUDE.md
│ │ ├── case_test.go
│ │ ├── ddl_test.go
│ │ ├── endtoend_test.go
│ │ ├── fmt_test.go
│ │ ├── json_schema_test.go
│ │ ├── testdata/
│ │ │ ├── accurate_cte/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── accurate_enum/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── accurate_sqlite/
│ │ │ │ └── sqlite/
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── accurate_star_expansion/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── alias/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── any/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── array_in/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── array_text/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── array_text_join/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── bad_config/
│ │ │ │ └── engine/
│ │ │ │ ├── query.sql
│ │ │ │ ├── sqlc.yaml
│ │ │ │ └── stderr.txt
│ │ │ ├── batch/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── batch.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── batch.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── batch_imports/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── batch.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── batch.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── batch_parameter_limit/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── batch.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── batch_parameter_type/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── batch.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── between_args/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── bit_string/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── build_tags/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── builtins/
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── aggfunc.sql.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── mathfunc.sql.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── scalarfunc.sql.go
│ │ │ │ ├── queries/
│ │ │ │ │ ├── aggfunc.sql
│ │ │ │ │ ├── mathfunc.sql
│ │ │ │ │ └── scalarfunc.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── case_named_params/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── case_sensitive/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── case_stmt_bool/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── case_text/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── case_value_param/
│ │ │ │ ├── issue.md
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.yaml
│ │ │ │ └── postgresql/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cast_coalesce/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cast_null/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cast_param/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cid_oid_tid_xid/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── citext/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── coalesce/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── coalesce_as/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pganalyze/
│ │ │ │ │ │ ├── exec.json
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── exec.json
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── exec.json
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── coalesce_join/
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── coalesce_params/
│ │ │ │ ├── issue.md
│ │ │ │ └── mysql/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── codegen_json/
│ │ │ │ ├── exec.json
│ │ │ │ ├── gen/
│ │ │ │ │ └── codegen.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ └── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── codegen_struct_field_names/
│ │ │ │ └── stdlib/
│ │ │ │ ├── README.md
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── column_alias/
│ │ │ │ ├── issue.md
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── column_as/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── comment_godoc/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── comment_godoc_db_argument/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── comment_on/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── comment_syntax/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── comparisons/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── composite_type/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── conflicted_arg_name/
│ │ │ │ └── postgresql/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── copyfrom/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── copyfrom_imports/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── copyfrom_multicolumn_parameter_limit/
│ │ │ │ └── mysql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── copyfrom_named_params/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── copyfrom_singlecolumn/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── copyfrom_singlecolumn_struct_only/
│ │ │ │ ├── issue.md
│ │ │ │ └── mysql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── count_star/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── create_materialized_view/
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── create_table_as/
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── create_table_like/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── create_view/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cte_count/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cte_filter/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cte_in_delete/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cte_join_self/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_left_join/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_multiple_alias/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_nested_with/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_recursive/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── cte_recursive_employees/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_recursive_star/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_recursive_subquery/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_recursive_union/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_select_one/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_update/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_update_multiple/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── cte_with_in/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pganalyze/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── data_type_boolean/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── db/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── datatype/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── sql/
│ │ │ │ │ │ ├── character.sql
│ │ │ │ │ │ ├── datetime.sql
│ │ │ │ │ │ ├── numeric.sql
│ │ │ │ │ │ └── query.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── sql/
│ │ │ │ │ │ │ ├── character.sql
│ │ │ │ │ │ │ ├── datetime.sql
│ │ │ │ │ │ │ ├── net-types.sql
│ │ │ │ │ │ │ ├── numeric.sql
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ └── rangetypes.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── sql/
│ │ │ │ │ │ ├── character.sql
│ │ │ │ │ │ ├── datetime.sql
│ │ │ │ │ │ ├── net-types.sql
│ │ │ │ │ │ ├── numeric.sql
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ └── rangetypes.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── sqlite/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── sql/
│ │ │ │ │ │ ├── character.sql
│ │ │ │ │ │ ├── datetime.sql
│ │ │ │ │ │ ├── numeric.sql
│ │ │ │ │ │ └── query.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── sql/
│ │ │ │ │ ├── character.sql
│ │ │ │ │ ├── datetime.sql
│ │ │ │ │ ├── net-types.sql
│ │ │ │ │ ├── numeric.sql
│ │ │ │ │ ├── query.sql
│ │ │ │ │ └── rangetypes.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_materialized_views_set_schema/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── ddl_alter_table_add_column/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_add_column_if_not_exists/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_alter_type/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_case_sensitivity/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_change_column/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_column_drop_not_null/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_drop_column/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_drop_column_if_exists/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_drop_constraint/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_if_exists/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_index/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_rename/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_rename_column/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_set_data_type/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_set_not_null/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_table_set_schema/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_type_add_value/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_type_rename/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_type_rename_and_update_columns/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_type_rename_value/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_alter_type_set_schema/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_comment/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── README.md
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_enum/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_func_exists/
│ │ │ │ ├── exec.json
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ ├── query.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── ddl_create_function/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_function_args/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_function_return/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_function_types/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_procedure/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table_include/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table_inherits/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table_invalid_inherits/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── ddl_create_table_like/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── ddl_create_table_partition/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table_reserved/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table_strict/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_table_unknown_type/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.yaml
│ │ │ │ └── stderr.txt
│ │ │ ├── ddl_create_table_without_rowid/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_create_trigger/
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_function/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_function_args/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_function_if_exists/
│ │ │ │ ├── mysql/
│ │ │ │ │ └── README.md
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_schema/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_schema_if_exists/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_table/
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_table_if_exists/
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_table_in_schema/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_type/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_type_if_exists/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_drop_type_in_schema/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_generated_columns/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_materialized_views_invalid/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.yaml
│ │ │ │ └── stderr.txt
│ │ │ ├── ddl_pg_temp/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── ddl_rename_drop_materialized_views/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.yaml
│ │ │ │ └── v5/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── delete_from/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── delete_inner_join/
│ │ │ │ └── mysql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── delete_join/
│ │ │ │ └── mysql/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── delete_using/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── diff_no_output/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── diff_output/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── do/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── db/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── pq/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── duplicate_go_names/
│ │ │ │ ├── enum/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.yaml
│ │ │ │ │ └── stderr.txt
│ │ │ │ ├── null_enum/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.yaml
│ │ │ │ │ └── stderr.txt
│ │ │ │ └── query_constant/
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.yaml
│ │ │ │ └── stderr.txt
│ │ │ ├── emit_db_and_json_tags/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_db_tags/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_empty_slices/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_enum_valid_and_values/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_exported_queries/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_methods_with_db_argument/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_pointers_for_null_types/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── sql/
│ │ │ │ │ │ │ ├── character.sql
│ │ │ │ │ │ │ ├── datetime.sql
│ │ │ │ │ │ │ ├── net-types.sql
│ │ │ │ │ │ │ ├── numeric.sql
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ └── rangetypes.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── sql/
│ │ │ │ │ │ ├── character.sql
│ │ │ │ │ │ ├── datetime.sql
│ │ │ │ │ │ ├── net-types.sql
│ │ │ │ │ │ ├── numeric.sql
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ └── rangetypes.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── sqlite/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── sql/
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ └── types.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── sql/
│ │ │ │ │ ├── character.sql
│ │ │ │ │ ├── datetime.sql
│ │ │ │ │ ├── net-types.sql
│ │ │ │ │ ├── numeric.sql
│ │ │ │ │ ├── query.sql
│ │ │ │ │ └── rangetypes.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_result_and_params_struct_pointers/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── batch.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── batch.go
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── emit_sql_as_comment/
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── enum/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── enum_column/
│ │ │ │ ├── issue.md
│ │ │ │ └── mysql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── enum_ordering/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── exec_create_table/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── db/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── mysql.query.sql.go
│ │ │ │ │ ├── mysql.query.sql
│ │ │ │ │ ├── mysql.schema.sql
│ │ │ │ │ └── sqlc.yaml
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── db/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── postgresql.query.sql.go
│ │ │ │ │ ├── postgresql.query.sql
│ │ │ │ │ ├── postgresql.schema.sql
│ │ │ │ │ └── sqlc.yaml
│ │ │ │ └── sqlite/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── sqlite.query.sql.go
│ │ │ │ ├── sqlc.yaml
│ │ │ │ ├── sqlite.query.sql
│ │ │ │ └── sqlite.schema.sql
│ │ │ ├── exec_imports/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── exec_lastid/
│ │ │ │ └── go_postgresql_stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── exec_no_return_struct/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── exec_result/
│ │ │ │ ├── go_postgresql_pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── go_postgresql_stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── exec_rows/
│ │ │ │ ├── go_postgresql_pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ ├── querier.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── go_postgresql_stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ ├── querier.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── full_outer_join/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_aggregate/
│ │ │ │ ├── pganalyze/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_args/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_args_typecast/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_call_cast/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_match_types/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_out_param/
│ │ │ │ ├── issue.md
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── func_return_date/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pganalyze/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pgx/
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_return_record/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── func_return_series/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── func_return_table/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── func_return_table_columns/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── func_star_expansion/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── func_variadic/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── geometric/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── go.mod
│ │ │ ├── go.sum
│ │ │ ├── golang_initialisms_empty/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── golang_initialisms_url/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── golang_invalid_sql_driver/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── golang_invalid_sql_package/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── having/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── hstore/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── hstore.sql.go
│ │ │ │ │ │ │ └── models.go
│ │ │ │ │ │ ├── hstore.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── hstore.sql.go
│ │ │ │ │ │ └── models.go
│ │ │ │ │ ├── hstore.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── hstore.sql.go
│ │ │ │ │ └── models.go
│ │ │ │ ├── hstore.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── identical_tables/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── identifier_case_sensitivity/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── identifier_dollar_sign/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── in_union/
│ │ │ │ └── mysql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── inflection/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── inflection_exclude_table_names/
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── v4/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── v5/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── insert_cte/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── insert_default_values/
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── insert_select/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── insert_select_case/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── insert_select_invalid/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr.txt
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ ├── sqlc.json
│ │ │ │ │ │ │ └── stderr/
│ │ │ │ │ │ │ ├── base.txt
│ │ │ │ │ │ │ └── managed-db.txt
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ ├── sqlc.json
│ │ │ │ │ │ └── stderr/
│ │ │ │ │ │ ├── base.txt
│ │ │ │ │ │ └── managed-db.txt
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr/
│ │ │ │ │ ├── base.txt
│ │ │ │ │ └── managed-db.txt
│ │ │ │ └── sqlite/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── insert_select_param/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── insert_values/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── insert_values_only/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── insert_values_public/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── interval/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── exec.json
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── invalid_func_args/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ ├── sqlc.json
│ │ │ │ │ │ └── stderr/
│ │ │ │ │ │ ├── base.txt
│ │ │ │ │ │ └── managed-db.txt
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr/
│ │ │ │ │ ├── base.txt
│ │ │ │ │ └── managed-db.txt
│ │ │ │ └── stdlib/
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr/
│ │ │ │ ├── base.txt
│ │ │ │ └── managed-db.txt
│ │ │ ├── invalid_group_by_reference/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr.txt
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr/
│ │ │ │ │ ├── base.txt
│ │ │ │ │ └── managed-db.txt
│ │ │ │ └── sqlite/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── invalid_insert_unknown_column/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── db/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── invalid_named_params/
│ │ │ │ └── mysql/
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── invalid_params/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ ├── sqlc.json
│ │ │ │ │ │ └── stderr/
│ │ │ │ │ │ ├── base.txt
│ │ │ │ │ │ └── managed-db.txt
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr/
│ │ │ │ │ ├── base.txt
│ │ │ │ │ └── managed-db.txt
│ │ │ │ └── stdlib/
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr/
│ │ │ │ ├── base.txt
│ │ │ │ └── managed-db.txt
│ │ │ ├── invalid_params_type_mismatch/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── invalid_queries_bar/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ ├── sqlc.json
│ │ │ │ │ │ └── stderr/
│ │ │ │ │ │ ├── base.txt
│ │ │ │ │ │ └── managed-db.txt
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr/
│ │ │ │ │ ├── base.txt
│ │ │ │ │ └── managed-db.txt
│ │ │ │ └── stdlib/
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr/
│ │ │ │ ├── base.txt
│ │ │ │ └── managed-db.txt
│ │ │ ├── invalid_queries_foo/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ ├── sqlc.json
│ │ │ │ │ │ └── stderr.txt
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr.txt
│ │ │ │ └── stdlib/
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── invalid_table_alias/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr.txt
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ ├── sqlc.json
│ │ │ │ │ └── stderr/
│ │ │ │ │ ├── base.txt
│ │ │ │ │ └── managed-db.txt
│ │ │ │ └── sqlite/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.json
│ │ │ │ └── stderr.txt
│ │ │ ├── invalid_update_unknown_column/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.yaml
│ │ │ │ └── stderr.txt
│ │ │ ├── join_alias/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_clauses_order/
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_from/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_full/
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_group_by_alias/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_inner/
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_left/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_left_same_table/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgres/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_left_table_alias/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── join_order_by/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── join_order_by_alias/
│ │ │ │ └── postgresql/
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_right/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_table_name/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_two_tables/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── join_update/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── join_using/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── join_validate_columns/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ ├── sqlc.yaml
│ │ │ │ └── stderr.txt
│ │ │ ├── join_where_clause/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── json/
│ │ │ │ ├── mysql/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── copyfrom.go
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── json_array_elements/
│ │ │ │ ├── issue.md
│ │ │ │ └── postgresql/
│ │ │ │ └── pgx/
│ │ │ │ ├── exec.json
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── json_build/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── json_param_type/
│ │ │ │ ├── issue.md
│ │ │ │ ├── postgresql/
│ │ │ │ │ └── pgx/
│ │ │ │ │ ├── exec.json
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.yaml
│ │ │ │ └── sqlite/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.yaml
│ │ │ ├── json_tags/
│ │ │ │ ├── camel_case/
│ │ │ │ │ └── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── pascal_case/
│ │ │ │ │ └── postgresql/
│ │ │ │ │ ├── pgx/
│ │ │ │ │ │ ├── v4/
│ │ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ │ └── v5/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── snake_case/
│ │ │ │ └── postgresql/
│ │ │ │ ├── pgx/
│ │ │ │ │ ├── v4/
│ │ │ │ │ │ ├── go/
│ │ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ │ ├── query.sql
│ │ │ │ │ │ ├── schema.sql
│ │ │ │ │ │ └── sqlc.json
│ │ │ │ │ └── v5/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ └── stdlib/
│ │ │ │ ├── go/
│ │ │ │ │ ├── db.go
│ │ │ │ │ ├── models.go
│ │ │ │ │ └── query.sql.go
│ │ │ │ ├── query.sql
│ │ │ │ ├── schema.sql
│ │ │ │ └── sqlc.json
│ │ │ ├── json_tags_null_enum/
│ │ │ │ ├── camel_case/
│ │ │ │ │ └── postgresql/
│ │ │ │ │ └── stdlib/
│ │ │ │ │ ├── go/
│ │ │ │ │ │ ├── db.go
│ │ │ │ │ │ ├── models.go
│ │ │ │ │ │ └── query.sql.go
│ │ │ │ │ ├── query.sql
│ │ │ │ │ ├── schema.sql
│ │ │ │ │ └── sqlc.json
│ │ │ │ ├── none/
│ │ │ │ │ └── postgresql/
│ │ │ │ │ └── stdlib/
│ │
================================================
FILE CONTENTS
================================================
================================================
FILE: .github/ISSUE_TEMPLATE/BUG_REPORT.yml
================================================
name: Bug Report
description: File a bug report
labels: [bug]
body:
- type: dropdown
id: version
attributes:
label: Version
description: What version of sqlc are you running? If you don't know, run `sqlc version`.
multiple: false
options:
- 1.30.0
- 1.29.0
- 1.28.0
- 1.27.0
- 1.26.0
- 1.25.0
- Other
validations:
required: true
- type: textarea
id: what-happened
attributes:
label: What happened?
description: Also tell us, what did you expect to happen?
placeholder: Tell us what you see!
value: "A bug happened!"
validations:
required: true
- type: textarea
id: logs
attributes:
label: Relevant log output
description: Please copy and paste any relevant log output. This will be automatically formatted into code, so no need for backticks.
render: shell
- type: textarea
id: schema
attributes:
label: Database schema
description: Please include definitions for the relevant database tables. This will be automatically formatted as SQL, so no need for backticks.
render: sql
- type: textarea
id: queries
attributes:
label: SQL queries
description: Please include the SQL queries causing issues. This will be automatically formatted as SQL, so no need for backticks.
render: sql
- type: textarea
id: config
attributes:
label: Configuration
description: Please include the sqlc.(yaml|yml) or sqlc.json file you using in your project. This will be automatically formatted, so no need for backticks.
render: yaml
- type: input
id: playground
attributes:
label: Playground URL
description: "Link to a reproduction of the issue on the sqlc playground"
placeholder: "https://play.sqlc.dev/"
- type: dropdown
id: os
attributes:
label: What operating system are you using?
multiple: true
options:
- Linux
- Windows
- macOS
- type: dropdown
id: engines
attributes:
label: What database engines are you using?
multiple: true
options:
- MySQL
- PostgreSQL
- SQLite
- type: dropdown
id: languages
attributes:
label: What type of code are you generating?
multiple: true
options:
- Go
- Python
- Kotlin
================================================
FILE: .github/ISSUE_TEMPLATE/FEATURE_REQUEST.yml
================================================
name: Feature Request
description: Request a new feature or a change to an existing feature
labels: [enhancement]
body:
- type: textarea
id: feature
attributes:
label: What do you want to change?
placeholder: Tell us what you want
value: "Free unicorns!"
validations:
required: true
- type: dropdown
id: engines
attributes:
label: What database engines need to be changed?
multiple: true
options:
- PostgreSQL
- MySQL
- SQLite
- type: dropdown
id: languages
attributes:
label: What programming language backends need to be changed?
multiple: true
options:
- Go
- Python
- Kotlin
================================================
FILE: .github/dependabot.yml
================================================
version: 2
updates:
- package-ecosystem: "gomod"
directory: "/"
schedule:
interval: "daily"
groups:
production-dependencies:
dependency-type: "production"
development-dependencies:
dependency-type: "development"
- package-ecosystem: "docker"
directory: "/"
schedule:
interval: "daily"
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
- package-ecosystem: "pip"
directory: "/docs"
schedule:
interval: "daily"
ignore:
# sphinx-rtd-theme does not support the latest versions of docutils and
# sphinx
- dependency-name: "docutils"
- dependency-name: "sphinx"
groups:
production-dependencies:
dependency-type: "production"
development-dependencies:
dependency-type: "development"
================================================
FILE: .github/workflows/buf.yml
================================================
name: buf
on: pull_request
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: bufbuild/buf-setup-action@v1
- uses: bufbuild/buf-lint-action@v1
================================================
FILE: .github/workflows/build.yml
================================================
name: build
on:
workflow_dispatch:
jobs:
build:
strategy:
matrix:
os: [ubuntu-24.04, macos-14, windows-2022]
name: build ${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26.0'
- name: install ./...
run: go build ./...
env:
CGO_ENABLED: "0"
================================================
FILE: .github/workflows/ci-kotlin.yml
================================================
name: kotlin
on:
push:
branches:
- main
pull_request:
jobs:
build:
if: false
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26.0'
- name: install ./...
run: go install ./...
- uses: actions/checkout@v6
with:
repository: sqlc-dev/sqlc-gen-kotlin
path: kotlin
- run: make test
working-directory: kotlin
- run: sqlc diff
working-directory: kotlin/examples
================================================
FILE: .github/workflows/ci-python.yml
================================================
name: python
on:
push:
branches:
- main
pull_request:
jobs:
build:
if: false
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26.0'
- name: install ./...
run: go install ./...
- uses: actions/checkout@v6
with:
repository: sqlc-dev/sqlc-gen-python
path: python
- run: make test
working-directory: python
- run: sqlc diff
working-directory: python/examples
================================================
FILE: .github/workflows/ci-typescript.yml
================================================
name: typescript
on:
push:
branches:
- main
pull_request:
jobs:
build:
if: false
name: test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26.0'
- name: install ./...
run: go install ./...
- uses: actions/checkout@v6
with:
repository: sqlc-dev/sqlc-gen-typescript
path: typescript
# v0.1.3
ref: daaf539092421adc15f6c3164279a3470716b560
- run: sqlc diff
working-directory: typescript/examples
================================================
FILE: .github/workflows/ci.yml
================================================
name: go
on:
push:
branches:
- main
pull_request:
jobs:
build:
strategy:
matrix:
goos: [darwin, linux, windows]
goarch: [amd64, arm64]
name: build ${{ matrix.goos }}/${{ matrix.goarch }}
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26.0'
- run: go build ./...
env:
CGO_ENABLED: "0"
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
test:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version: '1.26.0'
- name: install gotestsum
run: go install gotest.tools/gotestsum@latest
- name: install sqlc-gen-test
run: go install github.com/sqlc-dev/sqlc-gen-test@v0.1.0
- name: install test-json-process-plugin
run: go install ./scripts/test-json-process-plugin/
- name: install ./...
run: go install ./...
env:
CGO_ENABLED: "0"
- name: build internal/endtoend
run: go build ./...
working-directory: internal/endtoend/testdata
env:
CGO_ENABLED: "0"
- name: install databases
run: go run ./cmd/sqlc-test-setup install
- name: start databases
run: go run ./cmd/sqlc-test-setup start
- name: test ./...
run: gotestsum --junitfile junit.xml -- --tags=examples -timeout 20m -failfast ./...
env:
CI_SQLC_PROJECT_ID: ${{ secrets.CI_SQLC_PROJECT_ID }}
CI_SQLC_AUTH_TOKEN: ${{ secrets.CI_SQLC_AUTH_TOKEN }}
SQLC_AUTH_TOKEN: ${{ secrets.CI_SQLC_AUTH_TOKEN }}
POSTGRESQL_SERVER_URI: "postgres://postgres:postgres@127.0.0.1:5432/postgres?sslmode=disable"
MYSQL_SERVER_URI: "root:mysecretpassword@tcp(127.0.0.1:3306)/mysql?multiStatements=true&parseTime=true"
CGO_ENABLED: "0"
vuln_check:
runs-on: ubuntu-24.04
timeout-minutes: 5
steps:
- uses: golang/govulncheck-action@v1
================================================
FILE: .github/workflows/gen.yml
================================================
name: sqlc-pg-gen
on:
workflow_dispatch:
jobs:
gen:
name: sqlc-pg-gen
runs-on: ubuntu-22.04
services:
postgres:
image: postgres:15.0-alpine
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: postgres
ports:
- 5432:5432
# needed because the postgres container does not provide a healthcheck
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
steps:
- uses: actions/checkout@v6
- uses: actions/setup-go@v6
with:
go-version-file: go.mod
check-latest: true
- run: go build -o sqlc-pg-gen ./internal/tools/sqlc-pg-gen
- run: mkdir -p gen/contrib
- run: ./sqlc-pg-gen gen
env:
PG_USER: postgres
PG_HOST: localhost
PG_DATABASE: postgres
PG_PASSWORD: postgres
PG_PORT: ${{ job.services.postgres.ports['5432'] }}
- name: Save results
uses: actions/upload-artifact@v6
with:
name: sqlc-pg-gen-results
path: gen
================================================
FILE: .gitignore
================================================
/.idea/
__pycache__
.DS_Store
.*.swp
# Devenv
.envrc
.direnv
.devenv*
devenv.local.nix
================================================
FILE: .readthedocs.yaml
================================================
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
# Required
version: 2
# Set the version of Python and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"
# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/conf.py
# We recommend specifying your dependencies to enable reproducible builds:
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
install:
- requirements: docs/requirements.txt
================================================
FILE: .vscode/settings.json
================================================
{
"files.insertFinalNewline": true
}
================================================
FILE: CLAUDE.md
================================================
# Claude Code Development Guide for sqlc
This document provides essential information for working with the sqlc codebase, including testing, development workflow, and code structure.
## Quick Start
### Prerequisites
- **Go 1.26.0+** - Required for building and testing
- **Docker & Docker Compose** - Required for integration tests with databases (local development)
- **Git** - For version control
## Database Setup with sqlc-test-setup
The `sqlc-test-setup` tool (`cmd/sqlc-test-setup/`) automates installing and starting PostgreSQL and MySQL for tests. Both commands are idempotent and safe to re-run.
### Install databases
```bash
go run ./cmd/sqlc-test-setup install
```
This will:
- Configure the apt proxy (if `http_proxy` is set, e.g. in Claude Code remote environments)
- Install PostgreSQL via apt
- Download and install MySQL 9 from Oracle's deb bundle
- Resolve all dependencies automatically
- Skip anything already installed
### Start databases
```bash
go run ./cmd/sqlc-test-setup start
```
This will:
- Start PostgreSQL and configure password auth (`postgres`/`postgres`)
- Start MySQL via `mysqld_safe` and set root password (`mysecretpassword`)
- Verify both connections
- Skip steps that are already done (running services, existing config)
Connection URIs after start:
- PostgreSQL: `postgres://postgres:postgres@127.0.0.1:5432/postgres?sslmode=disable`
- MySQL: `root:mysecretpassword@tcp(127.0.0.1:3306)/mysql`
### Run tests
```bash
# Full test suite (requires databases running)
go test --tags=examples -timeout 20m ./...
```
## Running Tests
### Basic Unit Tests (No Database Required)
```bash
go test ./...
```
### Full Test Suite with Docker (Local Development)
```bash
docker compose up -d
go test --tags=examples -timeout 20m ./...
```
### Full Test Suite without Docker (Remote / CI)
```bash
go run ./cmd/sqlc-test-setup install
go run ./cmd/sqlc-test-setup start
go test --tags=examples -timeout 20m ./...
```
### Running Specific Tests
```bash
# Test a specific package
go test ./internal/config
# Run with verbose output
go test -v ./internal/config
# Run a specific test function
go test -v ./internal/config -run TestConfig
# Run with race detector (recommended for concurrency changes)
go test -race ./internal/config
```
## Test Types
### 1. Unit Tests
- **Location:** Throughout the codebase as `*_test.go` files
- **Run without:** Database or external dependencies
- **Examples:**
- `/internal/config/config_test.go` - Configuration parsing
- `/internal/compiler/selector_test.go` - Compiler logic
- `/internal/metadata/metadata_test.go` - Query metadata parsing
### 2. End-to-End Tests
- **Location:** `/internal/endtoend/`
- **Requirements:** `--tags=examples` flag and running databases
- **Tests:**
- `TestExamples` - Main end-to-end tests
- `TestReplay` - Replay tests
- `TestFormat` - Code formatting tests
- `TestJsonSchema` - JSON schema validation
- `TestExamplesVet` - Static analysis tests
### 3. Example Tests
- **Location:** `/examples/` directory
- **Requirements:** Tagged with "examples", requires live databases
- **Databases:** PostgreSQL, MySQL, SQLite examples
## Database Services
The `docker-compose.yml` provides test databases:
- **PostgreSQL 16** - Port 5432
- User: `postgres`
- Password: `mysecretpassword`
- Database: `postgres`
- **MySQL 9** - Port 3306
- User: `root`
- Password: `mysecretpassword`
- Database: `dinotest`
## Makefile Targets
```bash
make test # Basic unit tests only
make test-examples # Tests with examples tag
make build-endtoend # Build end-to-end test data
make test-ci # Full CI suite (examples + endtoend + vet)
make vet # Run go vet
make start # Start database containers
```
## CI/CD Configuration
### GitHub Actions Workflow
- **File:** `.github/workflows/ci.yml`
- **Go Version:** 1.26.0
- **Database Setup:** Uses `sqlc-test-setup` (not Docker) to install and start PostgreSQL and MySQL directly on the runner
- **Test Command:** `gotestsum --junitfile junit.xml -- --tags=examples -timeout 20m ./...`
- **Additional Checks:** `govulncheck` for vulnerability scanning
## Development Workflow
### Building Development Versions
```bash
# Build main sqlc binary for development
go build -o ~/go/bin/sqlc-dev ./cmd/sqlc
# Build JSON plugin (required for some tests)
go build -o ~/go/bin/sqlc-gen-json ./cmd/sqlc-gen-json
```
### Environment Variables for Tests
You can override database connections via environment variables:
```bash
POSTGRESQL_SERVER_URI="postgres://postgres:postgres@localhost:5432/postgres?sslmode=disable"
MYSQL_SERVER_URI="root:mysecretpassword@tcp(127.0.0.1:3306)/mysql?multiStatements=true&parseTime=true"
```
## Code Structure
### Key Directories
- `/cmd/` - Main binaries (sqlc, sqlc-gen-json, sqlc-test-setup)
- `/internal/cmd/` - Command implementations (vet, generate, etc.)
- `/internal/engine/` - Database engine implementations
- `/postgresql/` - PostgreSQL parser and converter
- `/dolphin/` - MySQL parser (uses TiDB parser)
- `/sqlite/` - SQLite parser
- `/internal/compiler/` - Query compilation logic
- `/internal/codegen/` - Code generation for different languages
- `/internal/config/` - Configuration file parsing
- `/internal/endtoend/` - End-to-end tests
- `/internal/sqltest/` - Test database setup (Docker, native, local detection)
- `/examples/` - Example projects for testing
### Important Files
- `/Makefile` - Build and test targets
- `/docker-compose.yml` - Database services for testing
- `/.github/workflows/ci.yml` - CI configuration
## Common Issues & Solutions
### Network Connectivity Issues
If you see errors about `storage.googleapis.com`, the Go proxy may be unreachable. Use `GOPROXY=direct go mod download` to fetch modules directly from source.
### Test Timeouts
End-to-end tests can take a while. Use longer timeouts:
```bash
go test -timeout 20m --tags=examples ./...
```
### Race Conditions
Always run tests with the race detector when working on concurrent code:
```bash
go test -race ./...
```
### Database Connection Failures
If using Docker:
```bash
docker compose ps
docker compose up -d
```
If using sqlc-test-setup:
```bash
go run ./cmd/sqlc-test-setup start
```
## Tips for Contributors
1. **Run tests before committing:** `go test --tags=examples -timeout 20m ./...`
2. **Check for race conditions:** Use `-race` flag when testing concurrent code
3. **Use specific package tests:** Faster iteration during development
4. **Read existing tests:** Good examples in `/internal/engine/postgresql/*_test.go`
## Git Workflow
### Branch Naming
- Feature branches should start with `claude/` for Claude Code work
- Branch names should be descriptive and end with the session ID
### Committing Changes
```bash
git add <files>
git commit -m "Brief description of changes"
git push -u origin <branch-name>
```
### Rebasing
```bash
git checkout main
git pull origin main
git checkout <feature-branch>
git rebase main
git push --force-with-lease origin <feature-branch>
```
## Resources
- **Main Documentation:** `/docs/`
- **Development Guide:** `/docs/guides/development.md`
- **CI Configuration:** `/.github/workflows/ci.yml`
- **Docker Compose:** `/docker-compose.yml`
================================================
FILE: Dockerfile
================================================
# STEP 1: Build sqlc
FROM golang:1.26.0 AS builder
COPY . /workspace
WORKDIR /workspace
ARG github_ref
ARG github_sha
ARG version
ENV GITHUB_REF=$github_ref
ENV GITHUB_SHA=$github_sha
ENV VERSION=$version
RUN go run scripts/release.go -docker
# STEP 2: Build a tiny image
FROM gcr.io/distroless/base-debian12
COPY --from=builder /workspace/sqlc /workspace/sqlc
ENTRYPOINT ["/workspace/sqlc"]
================================================
FILE: LICENSE
================================================
MIT License
Copyright (c) 2024 Riza, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
================================================
FILE: Makefile
================================================
.PHONY: build build-endtoend test test-ci test-examples test-endtoend start psql mysqlsh proto
build:
go build ./...
install:
go install ./...
test:
go test ./...
test-managed:
MYSQL_SERVER_URI="invalid" POSTGRESQL_SERVER_URI="postgres://postgres:mysecretpassword@localhost:5432/postgres" go test -v ./...
vet:
go vet ./...
test-examples:
go test --tags=examples ./...
build-endtoend:
cd ./internal/endtoend/testdata && go build ./...
test-ci: test-examples build-endtoend vet
sqlc-dev:
go build -o ~/bin/sqlc-dev ./cmd/sqlc/
sqlc-pg-gen:
go build -o ~/bin/sqlc-pg-gen ./internal/tools/sqlc-pg-gen
sqlc-gen-json:
go build -o ~/bin/sqlc-gen-json ./cmd/sqlc-gen-json
test-json-process-plugin:
go build -o ~/bin/test-json-process-plugin ./scripts/test-json-process-plugin/
start:
docker compose up -d
fmt:
go fmt ./...
psql:
PGPASSWORD=mysecretpassword psql --host=127.0.0.1 --port=5432 --username=postgres dinotest
mysqlsh:
mysqlsh --sql --user root --password mysecretpassword --database dinotest 127.0.0.1:3306
proto:
buf generate
remote-proto:
protoc \
--go_out=. --go_opt="Minternal/remote/gen.proto=github.com/sqlc-dev/sqlc/internal/remote" --go_opt=module=github.com/sqlc-dev/sqlc \
--go-grpc_out=. --go-grpc_opt="Minternal/remote/gen.proto=github.com/sqlc-dev/sqlc/internal/remote" --go-grpc_opt=module=github.com/sqlc-dev/sqlc \
internal/remote/gen.proto
================================================
FILE: README.md
================================================
# sqlc: A SQL Compiler

[](https://goreportcard.com/report/github.com/sqlc-dev/sqlc)
sqlc generates **type-safe code** from SQL. Here's how it works:
1. You write queries in SQL.
1. You run sqlc to generate code with type-safe interfaces to those queries.
1. You write application code that calls the generated code.
Check out [an interactive example](https://play.sqlc.dev/) to see it in action, and the [introductory blog post](https://conroy.org/introducing-sqlc) for the motivation behind sqlc.
## Overview
- [Documentation](https://docs.sqlc.dev)
- [Installation](https://docs.sqlc.dev/en/latest/overview/install.html)
- [Playground](https://play.sqlc.dev)
- [Website](https://sqlc.dev)
- [Downloads](https://downloads.sqlc.dev/)
- [Community](https://discord.gg/EcXzGe5SEs)
## Supported languages
- [sqlc-gen-go](https://github.com/sqlc-dev/sqlc-gen-go)
- [sqlc-gen-kotlin](https://github.com/sqlc-dev/sqlc-gen-kotlin)
- [sqlc-gen-python](https://github.com/sqlc-dev/sqlc-gen-python)
- [sqlc-gen-typescript](https://github.com/sqlc-dev/sqlc-gen-typescript)
Additional languages can be added via [plugins](https://docs.sqlc.dev/en/latest/reference/language-support.html#community-language-support).
## Sponsors
Development is possible thanks to our sponsors. If you would like to support sqlc,
please consider [sponsoring on GitHub](https://github.com/sponsors/kyleconroy).
<p align="center">
<a href="https://riza.io?utm_source=sqlc+readme"><img width=400 src="https://sqlc.dev/sponsors/riza-readme.png" alt="Riza.io"></a>
</p>
<p align="center">
<a href="https://coder.com?utm_source=sqlc+readme"><img width=200 src="https://sqlc.dev/sponsors/coder-readme.png" alt="Coder.com" /></a>
<a href="https://mint.fun?utm_source=sqlc+readme"><img width=200 src="https://sqlc.dev/sponsors/mint-readme.png" alt="Mint.fun" /></a>
<a href="https://mux.com?utm_source=sqlc+readme"><img width=200 src="https://sqlc.dev/sponsors/mux-readme.png" alt="Mux.com" /></a>
</p>
<p align="center">
<a href="https://github.com/Cyberax">Cyberax</a> -
<a href="https://github.com/NaNuNaNu">NaNuNaNu</a> -
<a href="https://github.com/Stumble">Stumble</a> -
<a href="https://github.com/WestfalNamur">WestfalNamur</a> -
<a href="https://github.com/alecthomas">alecthomas</a> -
<a href="https://github.com/cameronnewman">cameronnewman</a> -
<a href="https://github.com/danielbprice">danielbprice</a> -
<a href="https://github.com/davherrmann">davherrmann</a> -
<a href="https://github.com/dvob">dvob</a> -
<a href="https://github.com/gilcrest">gilcrest</a> -
<a href="https://github.com/gzuidhof">gzuidhof</a> -
<a href="https://github.com/jeffreylo">jeffreylo</a> -
<a href="https://github.com/mmcloughlin">mmcloughlin</a> -
<a href="https://github.com/ryohei1216">ryohei1216</a> -
<a href="https://github.com/sgielen">sgielen</a>
</p>
================================================
FILE: buf.gen.yaml
================================================
version: v1
managed:
enabled: true
go_package_prefix:
default: "github.com/sqlc-dev/sqlc/internal"
plugins:
- plugin: buf.build/protocolbuffers/go:v1.30.0
out: internal
opt: paths=source_relative
- plugin: buf.build/grpc/go:v1.3.0
out: internal
opt: paths=source_relative
================================================
FILE: buf.work.yaml
================================================
version: v1
directories:
- protos
================================================
FILE: cliff.toml
================================================
# configuration file for git-cliff (0.1.0)
[changelog]
# changelog header
header = """
# Changelog
All notable changes to this project will be documented in this file.\n
"""
# template for the changelog body
# https://tera.netlify.app/docs/#introduction
body = """
{% if version %}\
## [{{ version | trim_start_matches(pat="v") }}](https://github.com/sqlc-dev/sqlc/releases/tag/{{ version }})
{% else %}\
## [unreleased]
{% endif %}\
Released {{ timestamp | date(format="%Y-%m-%d") }}
{% for group, commits in commits | group_by(attribute="group") %}
### {{ group | upper_first }}
{% for commit in commits %}
- {%if commit.scope %}({{commit.scope}}) {% endif %}{{ commit.message | upper_first }}\
{% endfor %}
{% endfor %}\n
"""
# remove the leading and trailing whitespaces from the template
trim = true
# changelog footer
footer = """
<!-- generated by git-cliff -->
"""
[git]
# allow only conventional commits
# https://www.conventionalcommits.org
conventional_commits = true
# regex for parsing and grouping commits
commit_parsers = [
{ message = "^feat", group = "Features"},
{ message = "^fix", group = "Bug Fixes"},
{ message = "^doc", group = "Documentation"},
{ message = "^perf", group = "Performance"},
{ message = "^refactor", group = "Refactor"},
{ message = "^style", group = "Styling"},
{ message = "^test", group = "Testing"},
{ message = "^chore\\(release\\): prepare for", skip = true},
{ message = "^chore", group = "Miscellaneous Tasks"},
{ body = ".*security", group = "Security"},
]
# filter out the commits that are not matched by commit parsers
filter_commits = false
# glob pattern for matching git tags
tag_pattern = "v[0-9]*"
# regex for skipping tags
skip_tags = "v*beta"
================================================
FILE: cmd/sqlc/main.go
================================================
package main
import (
"os"
"github.com/sqlc-dev/sqlc/internal/cmd"
)
func main() {
os.Exit(cmd.Do(os.Args[1:], os.Stdin, os.Stdout, os.Stderr))
}
================================================
FILE: cmd/sqlc-gen-json/main.go
================================================
package main
import (
"bufio"
"context"
"fmt"
"io"
"os"
"github.com/sqlc-dev/sqlc/internal/codegen/json"
"github.com/sqlc-dev/sqlc/internal/plugin"
"google.golang.org/protobuf/proto"
)
func main() {
if err := run(); err != nil {
fmt.Fprintf(os.Stderr, "error generating JSON: %s", err)
os.Exit(2)
}
}
func run() error {
var req plugin.GenerateRequest
reqBlob, err := io.ReadAll(os.Stdin)
if err != nil {
return err
}
if err := proto.Unmarshal(reqBlob, &req); err != nil {
return err
}
resp, err := json.Generate(context.Background(), &req)
if err != nil {
return err
}
respBlob, err := proto.Marshal(resp)
if err != nil {
return err
}
w := bufio.NewWriter(os.Stdout)
if _, err := w.Write(respBlob); err != nil {
return err
}
if err := w.Flush(); err != nil {
return err
}
return nil
}
================================================
FILE: cmd/sqlc-test-setup/main.go
================================================
package main
import (
"crypto/sha256"
"encoding/hex"
"fmt"
"io"
"log"
"net/http"
"os"
"os/exec"
"path/filepath"
"runtime"
"strings"
"time"
)
const (
// pgVersion is the PostgreSQL version to install.
pgVersion = "18.2.0"
)
// pgBinary contains the download information for a PostgreSQL binary release.
type pgBinary struct {
URL string
SHA256 string
}
// pgBinaries maps "<GOOS>/<GOARCH>" to the corresponding binary download info.
var pgBinaries = map[string]pgBinary{
"linux/amd64": {
URL: "https://github.com/theseus-rs/postgresql-binaries/releases/download/" + pgVersion + "/postgresql-" + pgVersion + "-x86_64-unknown-linux-gnu.tar.gz",
SHA256: "cc2674e1641aa2a62b478971a22c131a768eb783f313e6a3385888f58a604074",
},
"linux/arm64": {
URL: "https://github.com/theseus-rs/postgresql-binaries/releases/download/" + pgVersion + "/postgresql-" + pgVersion + "-aarch64-unknown-linux-gnu.tar.gz",
SHA256: "8b415a11c7a5484e5fbf7a57fca71554d2d1d7acd34faf066606d2fee1261854",
},
}
func main() {
log.SetFlags(log.Ltime)
log.SetPrefix("[sqlc-test-setup] ")
if len(os.Args) < 2 {
fmt.Fprintln(os.Stderr, "usage: sqlc-test-setup <install|start>")
os.Exit(1)
}
switch os.Args[1] {
case "install":
if err := runInstall(); err != nil {
log.Fatalf("install failed: %s", err)
}
case "start":
if err := runStart(); err != nil {
log.Fatalf("start failed: %s", err)
}
default:
fmt.Fprintf(os.Stderr, "unknown command: %s\nusage: sqlc-test-setup <install|start>\n", os.Args[1])
os.Exit(1)
}
}
// run executes a command with verbose logging, streaming output to stderr.
func run(name string, args ...string) error {
log.Printf("exec: %s %s", name, strings.Join(args, " "))
cmd := exec.Command(name, args...)
cmd.Stdout = os.Stderr
cmd.Stderr = os.Stderr
cmd.Stdin = os.Stdin
return cmd.Run()
}
// runOutput executes a command and returns its combined output.
func runOutput(name string, args ...string) (string, error) {
log.Printf("exec: %s %s", name, strings.Join(args, " "))
cmd := exec.Command(name, args...)
out, err := cmd.CombinedOutput()
return string(out), err
}
// commandExists checks if a binary is available in PATH.
func commandExists(name string) bool {
_, err := exec.LookPath(name)
return err == nil
}
// isMySQLVersionOK checks if the mysqld --version output indicates MySQL 9+.
// Example version string: "/usr/sbin/mysqld Ver 8.0.44-0ubuntu0.24.04.2 ..."
func isMySQLVersionOK(versionOutput string) bool {
// Look for "Ver X.Y.Z" pattern
fields := strings.Fields(versionOutput)
for i, f := range fields {
if strings.EqualFold(f, "Ver") && i+1 < len(fields) {
ver := strings.Split(fields[i+1], ".")
if len(ver) > 0 {
major := strings.TrimLeft(ver[0], "0")
if major == "" {
return false
}
return major[0] >= '9'
}
}
}
return false
}
// pgBaseDir returns the sqlc-specific directory where PostgreSQL is installed,
// using the user's cache directory (~/.cache/sqlc/postgresql on Linux).
func pgBaseDir() string {
cacheDir, err := os.UserCacheDir()
if err != nil {
cacheDir = filepath.Join(os.Getenv("HOME"), ".cache")
}
return filepath.Join(cacheDir, "sqlc", "postgresql")
}
// pgBinDir returns the path to the PostgreSQL bin directory.
func pgBinDir() string {
return filepath.Join(pgBaseDir(), "bin")
}
// pgDataDir returns the path to the PostgreSQL data directory.
func pgDataDir() string {
return filepath.Join(pgBaseDir(), "data")
}
// pgBin returns the full path to a PostgreSQL binary.
func pgBin(name string) string {
return filepath.Join(pgBinDir(), name)
}
// ---- install ----
func runInstall() error {
log.Println("=== Installing PostgreSQL and MySQL for test setup ===")
if err := installAptProxy(); err != nil {
return fmt.Errorf("configuring apt proxy: %w", err)
}
if err := installPostgreSQL(); err != nil {
return fmt.Errorf("installing postgresql: %w", err)
}
if err := installMySQL(); err != nil {
return fmt.Errorf("installing mysql: %w", err)
}
log.Println("=== Install complete ===")
return nil
}
func installAptProxy() error {
proxy := os.Getenv("http_proxy")
if proxy == "" {
log.Println("http_proxy is not set, skipping apt proxy configuration")
return nil
}
const confPath = "/etc/apt/apt.conf.d/99proxy"
if _, err := os.Stat(confPath); err == nil {
log.Printf("apt proxy config already exists at %s, skipping", confPath)
return nil
}
log.Printf("configuring apt proxy to use %s", proxy)
proxyConf := fmt.Sprintf("Acquire::http::Proxy \"%s\";", proxy)
cmd := fmt.Sprintf("echo '%s' | sudo tee /etc/apt/apt.conf.d/99proxy", proxyConf)
return run("bash", "-c", cmd)
}
func installPostgreSQL() error {
log.Println("--- Installing PostgreSQL ---")
// Install runtime dependencies needed by PostgreSQL extensions (e.g.
// uuid-ossp requires libossp-uuid16).
if err := installPgDeps(); err != nil {
return fmt.Errorf("installing postgresql dependencies: %w", err)
}
// Check if already installed in our directory
if _, err := os.Stat(pgBin("postgres")); err == nil {
out, err := runOutput(pgBin("postgres"), "--version")
if err == nil {
log.Printf("postgresql is already installed: %s", strings.TrimSpace(out))
log.Println("skipping postgresql installation")
return nil
}
}
platform := runtime.GOOS + "/" + runtime.GOARCH
bin, ok := pgBinaries[platform]
if !ok {
return fmt.Errorf("unsupported platform: %s (supported: %s)", platform, supportedPlatforms())
}
// Download to a temp file
tarball := filepath.Join(os.TempDir(), fmt.Sprintf("postgresql-%s.tar.gz", pgVersion))
if _, err := os.Stat(tarball); err != nil {
log.Printf("downloading PostgreSQL %s from %s", pgVersion, bin.URL)
if err := downloadFile(tarball, bin.URL); err != nil {
os.Remove(tarball)
return fmt.Errorf("downloading postgresql: %w", err)
}
} else {
log.Printf("postgresql tarball already downloaded at %s", tarball)
}
// Verify SHA256 checksum
log.Printf("verifying SHA256 checksum")
actualHash, err := sha256File(tarball)
if err != nil {
return fmt.Errorf("computing sha256: %w", err)
}
if actualHash != bin.SHA256 {
os.Remove(tarball)
return fmt.Errorf("SHA256 mismatch: expected %s, got %s", bin.SHA256, actualHash)
}
log.Printf("SHA256 checksum verified: %s", actualHash)
baseDir := pgBaseDir()
// Create the base directory in the user cache
if err := os.MkdirAll(baseDir, 0o755); err != nil {
return fmt.Errorf("creating %s: %w", baseDir, err)
}
// Extract the tarball - it contains a top-level directory like
// postgresql-18.2.0-x86_64-unknown-linux-gnu/ with bin/, lib/, share/ inside.
// We strip that top-level directory and extract directly into the base dir.
log.Printf("extracting postgresql to %s", baseDir)
if err := run("tar", "-xzf", tarball, "-C", baseDir, "--strip-components=1"); err != nil {
return fmt.Errorf("extracting postgresql: %w", err)
}
// Verify the binary works
out, err := runOutput(pgBin("postgres"), "--version")
if err != nil {
return fmt.Errorf("postgres --version failed after install: %w", err)
}
log.Printf("postgresql installed successfully: %s", strings.TrimSpace(out))
return nil
}
// installPgDeps installs shared libraries required by PostgreSQL extensions at
// runtime (e.g. libossp-uuid16 for uuid-ossp).
func installPgDeps() error {
log.Println("installing postgresql runtime dependencies")
if err := run("sudo", "apt-get", "install", "-y", "--no-install-recommends", "libossp-uuid16"); err != nil {
return fmt.Errorf("apt-get install libossp-uuid16: %w", err)
}
return nil
}
// supportedPlatforms returns a comma-separated list of supported platforms.
func supportedPlatforms() string {
platforms := make([]string, 0, len(pgBinaries))
for p := range pgBinaries {
platforms = append(platforms, p)
}
return strings.Join(platforms, ", ")
}
// downloadFile downloads a URL to a local file path.
func downloadFile(filepath string, url string) error {
resp, err := http.Get(url)
if err != nil {
return err
}
defer resp.Body.Close()
if resp.StatusCode != http.StatusOK {
return fmt.Errorf("HTTP %d: %s", resp.StatusCode, resp.Status)
}
out, err := os.Create(filepath)
if err != nil {
return err
}
defer out.Close()
_, err = io.Copy(out, resp.Body)
return err
}
// sha256File computes the SHA256 hash of a file and returns the hex string.
func sha256File(path string) (string, error) {
f, err := os.Open(path)
if err != nil {
return "", err
}
defer f.Close()
h := sha256.New()
if _, err := io.Copy(h, f); err != nil {
return "", err
}
return hex.EncodeToString(h.Sum(nil)), nil
}
func installMySQL() error {
log.Println("--- Installing MySQL 9 ---")
if commandExists("mysqld") {
out, err := runOutput("mysqld", "--version")
if err == nil {
version := strings.TrimSpace(out)
log.Printf("mysql is already installed: %s", version)
if isMySQLVersionOK(version) {
log.Println("mysql version is 9+, skipping installation")
return nil
}
log.Println("mysql version is too old, upgrading to MySQL 9")
// Stop existing MySQL before upgrading
_ = exec.Command("sudo", "service", "mysql", "stop").Run()
_ = exec.Command("sudo", "pkill", "-f", "mysqld").Run()
time.Sleep(2 * time.Second)
// Remove old MySQL packages to avoid conflicts
log.Println("removing old mysql packages")
_ = run("sudo", "apt-get", "remove", "-y", "mysql-server", "mysql-client", "mysql-common",
"mysql-server-core-*", "mysql-client-core-*")
// Clear old data directory so MySQL 9 can initialize fresh
log.Println("clearing old mysql data directory")
_ = run("sudo", "rm", "-rf", "/var/lib/mysql")
_ = run("sudo", "mkdir", "-p", "/var/lib/mysql")
_ = run("sudo", "chown", "mysql:mysql", "/var/lib/mysql")
}
}
bundleURL := "https://dev.mysql.com/get/Downloads/MySQL-9.1/mysql-server_9.1.0-1ubuntu24.04_amd64.deb-bundle.tar"
bundleTar := "/tmp/mysql-server-bundle.tar"
extractDir := "/tmp/mysql9"
if _, err := os.Stat(bundleTar); err != nil {
log.Printf("downloading MySQL 9 bundle from %s", bundleURL)
if err := run("curl", "-L", "-o", bundleTar, bundleURL); err != nil {
return fmt.Errorf("downloading mysql bundle: %w", err)
}
} else {
log.Printf("mysql bundle already downloaded at %s, skipping download", bundleTar)
}
log.Printf("extracting bundle to %s", extractDir)
if err := os.MkdirAll(extractDir, 0o755); err != nil {
return fmt.Errorf("creating extract dir: %w", err)
}
if err := run("tar", "-xf", bundleTar, "-C", extractDir); err != nil {
return fmt.Errorf("extracting mysql bundle: %w", err)
}
// Install packages in dependency order using dpkg.
// Some packages may fail due to missing dependencies, which is expected.
// We fix them all at the end with apt-get install -f.
packages := []string{
"mysql-common_*.deb",
"mysql-community-client-plugins_*.deb",
"mysql-community-client-core_*.deb",
"mysql-community-client_*.deb",
"mysql-client_*.deb",
"mysql-community-server-core_*.deb",
"mysql-community-server_*.deb",
"mysql-server_*.deb",
}
for _, pkg := range packages {
log.Printf("installing %s (dependency errors will be fixed afterwards)", pkg)
cmd := fmt.Sprintf("sudo dpkg -i %s/%s", extractDir, pkg)
if err := run("bash", "-c", cmd); err != nil {
log.Printf("dpkg reported errors for %s (will fix with apt-get install -f)", pkg)
}
}
log.Println("fixing missing dependencies with apt-get install -f")
if err := run("sudo", "apt-get", "install", "-f", "-y"); err != nil {
return fmt.Errorf("apt-get install -f: %w", err)
}
log.Println("mysql 9 installed successfully")
return nil
}
// ---- start ----
func runStart() error {
log.Println("=== Starting PostgreSQL and MySQL ===")
if err := startPostgreSQL(); err != nil {
return fmt.Errorf("starting postgresql: %w", err)
}
if err := startMySQL(); err != nil {
return fmt.Errorf("starting mysql: %w", err)
}
log.Println("=== Both databases are running and configured ===")
log.Println("PostgreSQL: postgres://postgres:postgres@127.0.0.1:5432/postgres?sslmode=disable")
log.Println("MySQL: root:mysecretpassword@tcp(127.0.0.1:3306)/mysql")
return nil
}
func startPostgreSQL() error {
log.Println("--- Starting PostgreSQL ---")
dataDir := pgDataDir()
logFile := filepath.Join(pgBaseDir(), "postgresql.log")
// Check if already running
if pgIsReady() {
log.Println("postgresql is already running and accepting connections")
return nil
}
// Initialize data directory if needed
if _, err := os.Stat(filepath.Join(dataDir, "PG_VERSION")); os.IsNotExist(err) {
log.Println("initializing postgresql data directory")
if err := os.MkdirAll(dataDir, 0o700); err != nil {
return fmt.Errorf("creating data directory: %w", err)
}
if err := run(pgBin("initdb"),
"-D", dataDir,
"--username=postgres",
"--auth=trust",
); err != nil {
return fmt.Errorf("initdb: %w", err)
}
// Configure pg_hba.conf for md5 password authentication on TCP
hbaPath := filepath.Join(dataDir, "pg_hba.conf")
if err := configurePgHBA(hbaPath); err != nil {
return fmt.Errorf("configuring pg_hba.conf: %w", err)
}
// Configure postgresql.conf to listen on localhost
confPath := filepath.Join(dataDir, "postgresql.conf")
if err := appendToFile(confPath,
"\n# sqlc-test-setup configuration\n"+
"listen_addresses = '127.0.0.1'\n"+
"port = 5432\n",
); err != nil {
return fmt.Errorf("configuring postgresql.conf: %w", err)
}
} else {
log.Println("postgresql data directory already initialized")
}
// Start PostgreSQL using pg_ctl
log.Println("starting postgresql")
if err := run(pgBin("pg_ctl"),
"-D", dataDir,
"-l", logFile,
"-o", fmt.Sprintf("-k %s", dataDir),
"start",
); err != nil {
return fmt.Errorf("pg_ctl start: %w", err)
}
// Wait for PostgreSQL to be ready
log.Println("waiting for postgresql to accept connections")
if err := waitForPostgreSQL(30 * time.Second); err != nil {
return fmt.Errorf("postgresql did not start in time: %w", err)
}
// Set the postgres user password
log.Println("setting password for postgres user")
if err := run(pgBin("psql"),
"-h", "127.0.0.1",
"-U", "postgres",
"-c", "ALTER USER postgres PASSWORD 'postgres';",
); err != nil {
return fmt.Errorf("setting postgres password: %w", err)
}
// Update pg_hba.conf to require md5 auth now that password is set
hbaPath := filepath.Join(dataDir, "pg_hba.conf")
if err := configurePgHBAWithMD5(hbaPath); err != nil {
return fmt.Errorf("updating pg_hba.conf for md5: %w", err)
}
// Reload configuration
log.Println("reloading postgresql configuration")
if err := run(pgBin("pg_ctl"), "-D", dataDir, "reload"); err != nil {
return fmt.Errorf("pg_ctl reload: %w", err)
}
// Verify connection with password
log.Println("verifying postgresql connection")
cmd := exec.Command(pgBin("psql"),
"-h", "127.0.0.1",
"-U", "postgres",
"-c", "SELECT 1;",
)
cmd.Env = append(os.Environ(), "PGPASSWORD=postgres")
cmd.Stdout = os.Stderr
cmd.Stderr = os.Stderr
if err := cmd.Run(); err != nil {
return fmt.Errorf("postgresql connection test failed: %w", err)
}
log.Println("postgresql is running and configured")
return nil
}
// configurePgHBA writes a pg_hba.conf that allows trust auth initially (for
// setting the password), then we switch to md5.
func configurePgHBA(hbaPath string) error {
content := `# pg_hba.conf - generated by sqlc-test-setup
# TYPE DATABASE USER ADDRESS METHOD
local all all trust
host all all 127.0.0.1/32 trust
host all all ::1/128 trust
`
return os.WriteFile(hbaPath, []byte(content), 0o600)
}
// configurePgHBAWithMD5 rewrites pg_hba.conf to use md5 for TCP connections.
func configurePgHBAWithMD5(hbaPath string) error {
content := `# pg_hba.conf - generated by sqlc-test-setup
# TYPE DATABASE USER ADDRESS METHOD
local all all trust
host all all 127.0.0.1/32 md5
host all all ::1/128 md5
`
return os.WriteFile(hbaPath, []byte(content), 0o600)
}
// appendToFile appends text to a file.
func appendToFile(path, text string) error {
f, err := os.OpenFile(path, os.O_APPEND|os.O_WRONLY, 0o644)
if err != nil {
return err
}
defer f.Close()
_, err = f.WriteString(text)
return err
}
// pgIsReady checks if PostgreSQL is running and accepting connections.
func pgIsReady() bool {
cmd := exec.Command(pgBin("pg_isready"), "-h", "127.0.0.1", "-p", "5432")
return cmd.Run() == nil
}
// waitForPostgreSQL polls until PostgreSQL accepts connections or times out.
func waitForPostgreSQL(timeout time.Duration) error {
deadline := time.Now().Add(timeout)
for time.Now().Before(deadline) {
if pgIsReady() {
return nil
}
time.Sleep(500 * time.Millisecond)
}
return fmt.Errorf("timed out after %s waiting for postgresql", timeout)
}
func startMySQL() error {
log.Println("--- Starting MySQL ---")
// Check if MySQL is already running and accessible with the expected password
if mysqlReady() {
log.Println("mysql is already running and accepting connections")
return verifyMySQL()
}
// Stop any existing MySQL service that might be running (e.g. pre-installed
// on GitHub Actions runners) to avoid port conflicts.
log.Println("stopping any existing mysql service")
_ = exec.Command("sudo", "service", "mysql", "stop").Run()
_ = exec.Command("sudo", "mysqladmin", "shutdown").Run()
// Give MySQL time to fully shut down
time.Sleep(2 * time.Second)
if err := ensureMySQLDirs(); err != nil {
return err
}
// Check if data directory already exists and has been initialized
needsPasswordReset := false
if mysqlInitialized() {
log.Println("mysql data directory already initialized, skipping initialization")
// Existing data dir may have an unknown root password (e.g. pre-installed
// MySQL on GitHub Actions). We'll need to use --skip-grant-tables to reset it.
needsPasswordReset = true
} else {
log.Println("initializing mysql data directory")
if err := run("sudo", "mysqld", "--initialize-insecure", "--user=mysql"); err != nil {
return fmt.Errorf("mysqld --initialize-insecure: %w", err)
}
}
if needsPasswordReset {
// Start with --skip-grant-tables to reset the unknown root password.
if err := startMySQLDaemon("--skip-grant-tables"); err != nil {
return err
}
log.Println("resetting root password via --skip-grant-tables")
resetSQL := "FLUSH PRIVILEGES; ALTER USER 'root'@'localhost' IDENTIFIED WITH caching_sha2_password BY 'mysecretpassword';"
if err := run("mysql", "-u", "root", "-e", resetSQL); err != nil {
return fmt.Errorf("resetting mysql root password: %w", err)
}
// Restart without --skip-grant-tables
log.Println("restarting mysql normally")
if err := run("sudo", "mysqladmin", "-u", "root", "-pmysecretpassword", "shutdown"); err != nil {
// If mysqladmin fails, try killing the process directly
_ = run("sudo", "pkill", "-f", "mysqld")
}
time.Sleep(2 * time.Second)
if err := startMySQLDaemon(); err != nil {
return err
}
} else {
// Fresh initialization — start normally and set password
if err := startMySQLDaemon(); err != nil {
return err
}
log.Println("setting mysql root password")
alterSQL := "ALTER USER 'root'@'localhost' IDENTIFIED WITH caching_sha2_password BY 'mysecretpassword'; FLUSH PRIVILEGES;"
if err := run("mysql", "-u", "root", "-e", alterSQL); err != nil {
return fmt.Errorf("setting mysql root password: %w", err)
}
}
return verifyMySQL()
}
// ensureMySQLDirs creates the directories MySQL needs at runtime.
func ensureMySQLDirs() error {
if err := run("sudo", "mkdir", "-p", "/var/run/mysqld"); err != nil {
return fmt.Errorf("creating /var/run/mysqld: %w", err)
}
if err := run("sudo", "chown", "mysql:mysql", "/var/run/mysqld"); err != nil {
return fmt.Errorf("chowning /var/run/mysqld: %w", err)
}
return nil
}
// startMySQLDaemon starts mysqld_safe in the background and waits for it to
// accept connections. Extra args (e.g. "--skip-grant-tables") are appended.
func startMySQLDaemon(extraArgs ...string) error {
args := append([]string{"mysqld_safe", "--user=mysql"}, extraArgs...)
log.Printf("starting mysql via mysqld_safe %v", extraArgs)
cmd := exec.Command("sudo", args...)
cmd.Stdout = os.Stderr
cmd.Stderr = os.Stderr
if err := cmd.Start(); err != nil {
return fmt.Errorf("starting mysqld_safe: %w", err)
}
log.Println("waiting for mysql to accept connections")
if err := waitForMySQL(30 * time.Second); err != nil {
return fmt.Errorf("mysql did not start in time: %w", err)
}
log.Println("mysql is accepting connections")
return nil
}
// mysqlReady checks if MySQL is running and accepting connections with the expected password.
func mysqlReady() bool {
err := exec.Command("mysqladmin", "-h", "127.0.0.1", "-u", "root", "-pmysecretpassword", "ping").Run()
return err == nil
}
// waitForMySQL polls until MySQL accepts connections or the timeout expires.
func waitForMySQL(timeout time.Duration) error {
deadline := time.Now().Add(timeout)
for time.Now().Before(deadline) {
// Try connecting without password (fresh) or with password (already configured)
if exec.Command("mysqladmin", "-u", "root", "ping").Run() == nil {
return nil
}
if exec.Command("mysqladmin", "-h", "127.0.0.1", "-u", "root", "-pmysecretpassword", "ping").Run() == nil {
return nil
}
time.Sleep(500 * time.Millisecond)
}
return fmt.Errorf("timed out after %s waiting for mysql", timeout)
}
func verifyMySQL() error {
log.Println("verifying mysql connection")
if err := run("mysql", "-h", "127.0.0.1", "-u", "root", "-pmysecretpassword", "-e", "SELECT VERSION();"); err != nil {
return fmt.Errorf("mysql connection test failed: %w", err)
}
log.Println("mysql is running and configured")
return nil
}
// mysqlInitialized checks if the MySQL data directory has been initialized.
// We use sudo ls because /var/lib/mysql is typically only readable by the
// mysql user, so filepath.Glob from a non-root process would silently fail.
func mysqlInitialized() bool {
out, err := exec.Command("sudo", "ls", "/var/lib/mysql").CombinedOutput()
if err != nil {
return false
}
// If the directory has any contents, consider it initialized.
// mysqld --initialize-insecure requires an empty directory.
return strings.TrimSpace(string(out)) != ""
}
================================================
FILE: devenv.nix
================================================
{ pkgs, ... }:
{
# https://devenv.sh/packages/
packages = [
pkgs.buf
pkgs.go_1_24
pkgs.git
pkgs.git-cliff
pkgs.govulncheck
pkgs.gopls
pkgs.golint
pkgs.mysql-shell
pkgs.postgresql_15
pkgs.python311
];
}
================================================
FILE: devenv.yaml
================================================
inputs:
nixpkgs:
url: github:NixOS/nixpkgs/nixpkgs-unstable
================================================
FILE: docker-compose.yml
================================================
version: "3.8"
services:
mysql:
image: "mysql:9"
ports:
- "3306:3306"
restart: always
environment:
MYSQL_DATABASE: dinotest
MYSQL_ROOT_PASSWORD: mysecretpassword
MYSQL_ROOT_HOST: '%'
postgresql:
image: "postgres:16"
ports:
- "5432:5432"
restart: always
environment:
POSTGRES_DB: postgres
POSTGRES_PASSWORD: mysecretpassword
POSTGRES_USER: postgres
================================================
FILE: docs/.gitignore
================================================
_venv
_build
================================================
FILE: docs/Makefile
================================================
# Minimal makefile for Sphinx documentation
#
# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
VENVDIR = _venv
BINDIR = $(VENVDIR)/bin
SPHINXBUILD = $(BINDIR)/sphinx-build
SOURCEDIR = .
BUILDDIR = _build
# Put it first so that "make" without argument is like "make help".
help: $(SPHINXBUILD)
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
$(SPHINXBUILD): $(VENVDIR)
$(VENVDIR)/bin/pip install -r requirements.txt
$(VENVDIR):
python3 -m venv $(VENVDIR)
.PHONY: help Makefile
# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
================================================
FILE: docs/_static/customize.css
================================================
.wy-side-nav-search img {
padding: 5px 60px !important;
}
#banner {
text-align: center;
background: #2980b9;
border: 1px solid rgb(52, 49, 49);
color: #F0F0F4;
padding: 10px;
margin-bottom: 1.618em;
}
#banner > div > a {
color: #F0F0F4;
text-decoration: underline;
}
#sponsorship > img {
width: 100%;
max-width: 200px;
}
================================================
FILE: docs/_templates/breadcrumbs.html
================================================
{% extends "!breadcrumbs.html" %}
{% block breadcrumbs %}
{% if show_banner %}
{% endif %}
{{ super() }}
{% endblock %}
================================================
FILE: docs/_templates/layout.html
================================================
{% extends "!layout.html" %}
{% block extrahead %}
<script defer data-domain="docs.sqlc.dev" data-api="https://proxy.sqlc.dev/api/event" src="https://proxy.sqlc.dev/js/script.js"></script>
{{ super() }}
{% endblock %}
{% block menu %}
{{ super() }}
<p class="caption" role="heading"><span class="caption-text">Sponsored By</span></p>
<div>
<a id="sponsorship" href="https://riza.io?utm_source=sqlc+docs">
<img src="https://sqlc.dev/sponsors/riza-readme.png" alt="Riza logo" />
</a>
</div>
{% endblock %}
================================================
FILE: docs/conf.py
================================================
# Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
# https://www.sphinx-doc.org/en/master/usage/configuration.html
# -- Path setup --------------------------------------------------------------
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
import os
# import sys
# sys.path.insert(0, os.path.abspath('.'))
import sphinx_rtd_theme
# -- Project information -----------------------------------------------------
project = 'sqlc'
copyright = '2024, Riza, Inc.'
author = 'Riza, Inc.'
# The full version, including alpha/beta/rc tags
release = '1.30.0'
# -- General configuration ---------------------------------------------------
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'myst_parser',
'sphinx_rtd_theme',
'sphinx_favicon',
'sphinxext.rediraffe',
]
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = ['_build', '_venv', 'Thumbs.db', '.DS_Store']
# -- Options for HTML output -------------------------------------------------
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'sphinx_rtd_theme'
# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']
html_logo = "_static/logo.png"
html_theme_options = {
'logo_only': True,
}
html_context = {
'show_banner': 'SHOW_LAUNCH_BANNER' in os.environ,
}
def setup(app):
app.add_css_file('customize.css')
favicons = [
"favicon.png",
]
myst_enable_extensions = [
"attrs_inline",
"colon_fence",
]
rediraffe_redirects = {
"howto/upload.md": "howto/push.md",
}
================================================
FILE: docs/guides/development.md
================================================
# Developing sqlc
## Building
For local development, install `sqlc` under an alias. We suggest `sqlc-dev`.
```
go build -o ~/go/bin/sqlc-dev ./cmd/sqlc
```
Install `sqlc-gen-json` to avoid test failure.
```
go build -o ~/go/bin/sqlc-gen-json ./cmd/sqlc-gen-json
```
## Running Tests
```
go test ./...
```
To run the tests in the examples folder, use the `examples` tag.
```
go test --tags=examples ./...
```
These tests require locally-running database instances. Run these databases
using [Docker Compose](https://docs.docker.com/compose/).
```
docker compose up -d
```
The tests use the following environment variables to connect to the
database
### For PostgreSQL
```
Variable Default Value
-------------------------
PG_HOST 127.0.0.1
PG_PORT 5432
PG_USER postgres
PG_PASSWORD mysecretpassword
PG_DATABASE dinotest
```
### For MySQL
```
Variable Default Value
-------------------------
MYSQL_HOST 127.0.0.1
MYSQL_PORT 3306
MYSQL_USER root
MYSQL_ROOT_PASSWORD mysecretpassword
MYSQL_DATABASE dinotest
```
================================================
FILE: docs/guides/migrating-off-hosted-managed-databases.md
================================================
# Migrating off hosted managed databases
Starting in sqlc 1.27.0, [managed databases](../docs/managed-databases.md) will require a database server URI in the configuration file.
This guide walks you through migrating to a locally running database server.
## Run a database server locally
There are many options for running a database server locally, but this guide
will use [Docker Compose](https://docs.docker.com/compose/), as it can support
both MySQL and PostgreSQL.
If you're using macOS and PostgreSQL, [Postgres.app](https://postgresapp.com/) is also a good option.
For MySQL, create a `docker-compose.yml` file with the following contents:
```yaml
version: "3.8"
services:
mysql:
image: "mysql/mysql-server:8.0"
ports:
- "3306:3306"
restart: always
environment:
MYSQL_DATABASE: dinotest
MYSQL_ROOT_PASSWORD: mysecretpassword
MYSQL_ROOT_HOST: '%'
```
For PostgreSQL, create a `docker-compose.yml` file with the following contents:
```yaml
version: "3.8"
services:
postgresql:
image: "postgres:16"
ports:
- "5432:5432"
restart: always
environment:
POSTGRES_DB: postgres
POSTGRES_PASSWORD: mysecretpassword
POSTGRES_USER: postgres
```
```sh
docker compose up -d
```
## Upgrade sqlc
You must be running sqlc v1.30.0 or greater to have access to the `servers`
configuration.
## Add servers to configuration
```diff
version: '2'
cloud:
project: '<PROJECT_ID>'
+ servers:
+ - name: mysql
+ uri: mysql://localhost:3306
+ - name: postgres
+ uri: postgres://localhost:5432/postgres?sslmode=disable
```
## Re-generate the code
Run `sqlc generate`. A database with the `sqlc_managed_` prefix will be automatically created and used for query analysis.
================================================
FILE: docs/guides/migrating-to-sqlc-gen-kotlin.md
================================================
# Migrating to sqlc-gen-kotlin
Starting in sqlc 1.16.0, built-in Kotlin support has been deprecated. It will
be fully removed in 1.17.0 in favor of sqlc-gen-kotlin.
This guide will walk you through migrating to the [sqlc-gen-kotlin](https://github.com/sqlc-dev/sqlc-gen-kotlin) plugin,
which involves three steps.
1. Add the sqlc-gen-kotlin plugin
2. Migrate each package
3. Re-generate the code
## Add the sqlc-gen-kotlin plugin
In your configuration file, add a `plugins` array if you don't have one
already. Add the following configuration for the plugin:
```json
{
"version": "2",
"plugins": [
{
"name": "kt",
"wasm": {
"url": "https://downloads.sqlc.dev/plugin/sqlc-gen-kotlin_1.0.0.wasm",
"sha256": "7620dc5d462de41fdc90e2011232c842117b416c98fd5c163d27c5738431a45c"
}
}
]
}
```
```yaml
version: "2"
plugins:
- name: "kt"
wasm:
url: "https://downloads.sqlc.dev/plugin/sqlc-gen-kotlin_1.0.0.wasm"
sha256: "7620dc5d462de41fdc90e2011232c842117b416c98fd5c163d27c5738431a45c"
```
## Migrate each package
Your package configuration should currently looks something like this for JSON.
```json
"sql": [
{
"schema": "schema.sql",
"queries": "query.sql",
"engine": "postgresql",
"gen": {
"kotlin": {
"out": "src/main/kotlin/com/example/foo",
"package": "com.example.foo"
}
}
}
]
```
Or this if you're using YAML.
```yaml
sql:
- schema: "schema.sql"
queries: "query.sql"
engine: "postgresql"
gen:
kotlin:
out: "src/main/kotlin/com/example/foo"
package: "com.example.foo"
```
To use the plugin, you'll need to replace the `gen` mapping with the `codegen`
collection. Add the `plugin` field, setting it to `kt`. All fields other than
`out` need to be moved into the `options` mapping.
After you're done, it should look like this for JSON.
```json
"sql": [
{
"schema": "schema.sql",
"queries": "query.sql",
"engine": "postgresql",
"codegen": [
{
"out": "src/main/kotlin/com/example/foo",
"plugin": "kt",
"options": {
"package": "com.example.foo"
}
}
]
}
]
```
Or this for YAML.
```yaml
sql:
- schema: "schema.sql"
queries: "query.sql"
engine: "postgresql"
codegen:
- plugin: "kt"
out: "src/main/kotlin/com/example/foo"
options:
package: "com.example.foo"
```
## Re-generate the code
Run `sqlc generate`. The plugin will produce the same output, so you shouldn't
see any changes. The first time `sqlc generate` is run, the plugin must be
downloaded and compiled, resulting in a slightly longer runtime. Subsequent
`generate` calls will be fast.
================================================
FILE: docs/guides/migrating-to-sqlc-gen-python.md
================================================
# Migrating to sqlc-gen-python
Starting in sqlc 1.16.0, built-in Python support has been deprecated. It will
be fully removed in 1.17.0 in favor of sqlc-gen-python.
This guide will walk you through migrating to the [sqlc-gen-python](https://github.com/sqlc-dev/sqlc-gen-python) plugin,
which involves three steps.
1. Add the sqlc-gen-python plugin
2. Migrate each package
3. Re-generate the code
## Add the sqlc-gen-python plugin
In your configuration file, add a `plugins` array if you don't have one
already. Add the following configuration for the plugin:
```json
{
"version": "2",
"plugins": [
{
"name": "py",
"wasm": {
"url": "https://downloads.sqlc.dev/plugin/sqlc-gen-python_1.0.0.wasm",
"sha256": "aca83e1f59f8ffdc604774c2f6f9eb321a2b23e07dc83fc12289d25305fa065b"
}
}
]
}
```
```yaml
version: "2"
plugins:
- name: "py"
wasm:
url: "https://downloads.sqlc.dev/plugin/sqlc-gen-python_1.0.0.wasm"
sha256: "aca83e1f59f8ffdc604774c2f6f9eb321a2b23e07dc83fc12289d25305fa065b"
```
## Migrate each package
Your package configuration should currently looks something like this for JSON.
```json
"sql": [
{
"schema": "schema.sql",
"queries": "query.sql",
"engine": "postgresql",
"gen": {
"python": {
"out": "src",
"package": "foo",
"emit_sync_querier": true,
"emit_async_querier": true,
"query_parameter_limit": 5
}
}
}
]
```
Or this if you're using YAML.
```yaml
sql:
- schema: "schema.sql"
queries: "query.sql"
engine: "postgresql"
gen:
python:
out: "src"
package: "foo"
emit_sync_querier: true
emit_async_querier: true
query_parameter_limit: 5
```
To use the plugin, you'll need to replace the `gen` mapping with the `codegen`
collection. Add the `plugin` field, setting it to `py`. All fields other than
`out` need to be moved into the `options` mapping.
After you're done, it should look like this for JSON.
```json
"sql": [
{
"schema": "schema.sql",
"queries": "query.sql",
"engine": "postgresql",
"codegen": [
{
"out": "src",
"plugin": "py",
"options": {
"package": "authors",
"emit_sync_querier": true,
"emit_async_querier": true,
"query_parameter_limit": 5
}
}
]
}
]
```
Or this for YAML.
```yaml
sql:
- schema: "schema.sql"
queries: "query.sql"
engine: "postgresql"
codegen:
- plugin: "py"
out: "src"
options:
package: "foo"
emit_sync_querier: true
emit_async_querier: true
query_parameter_limit: 5
```
## Re-generate the code
Run `sqlc generate`. The plugin will produce the same output, so you shouldn't
see any changes. The first time `sqlc generate` is run, the plugin must be
downloaded and compiled, resulting in a slightly longer runtime. Subsequent
`generate` calls will be fast.
================================================
FILE: docs/guides/plugins.md
================================================
# Using plugins
To use plugins, you must be using [Version 2](../reference/config.md#version-2) of
the configuration file. The top-level `plugins` array defines the available
plugins.
## WASM plugins
> WASM plugins are fully sandboxed; they do not have access to the network,
> filesystem, or environment variables.
In the `codegen` section, the `out` field dictates what directory will contain
the new files. The `plugin` key must reference a plugin defined in the
top-level `plugins` map. Any `options` are serialized to a string as JSON and
passed on to the plugin itself.
```yaml
version: '2'
plugins:
- name: greeter
wasm:
url: https://github.com/sqlc-dev/sqlc-gen-greeter/releases/download/v0.1.0/sqlc-gen-greeter.wasm
sha256: afc486dac2068d741d7a4110146559d12a013fd0286f42a2fc7dcd802424ad07
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
codegen:
- out: gen
plugin: greeter
options:
lang: en-US
```
For a complete working example see the following files:
- [sqlc-gen-greeter](https://github.com/sqlc-dev/sqlc-gen-greeter)
- A WASM plugin (written in Rust) that outputs a friendly message
- [wasm_plugin_sqlc_gen_greeter](https://github.com/sqlc-dev/sqlc/tree/main/internal/endtoend/testdata/wasm_plugin_sqlc_gen_greeter)
- An example project showing how to use a WASM plugin
## Process plugins
> Process-based plugins offer minimal security. Only use plugins that you
> trust. Better yet, only use plugins that you've written yourself.
In the `codegen` section, the `out` field dictates what directory will contain
the new files. The `plugin` key must reference a plugin defined in the
top-level `plugins` map. Any `options` are serialized to a string as JSON and
passed on to the plugin itself.
```yaml
version: '2'
plugins:
- name: jsonb
process:
cmd: sqlc-gen-json
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
codegen:
- out: gen
plugin: jsonb
options:
indent: " "
filename: codegen.json
```
For a complete working example see the following files:
- [sqlc-gen-json](https://github.com/sqlc-dev/sqlc/tree/main/cmd/sqlc-gen-json)
- A process-based plugin that serializes the CodeGenRequest to JSON
- [process_plugin_sqlc_gen_json](https://github.com/sqlc-dev/sqlc/tree/main/internal/endtoend/testdata/process_plugin_sqlc_gen_json)
- An example project showing how to use a process-based plugin
- [process_plugin_sqlc_gen_json](https://github.com/sqlc-dev/sqlc/tree/main/internal/endtoend/testdata/process_plugin_format_json/)
- An example project showing how to use a process-based plugin using json
## Environment variables
By default, plugins do not inherit access to environment variables. Instead,
you can configure access on a per-variable basis. For example, if your plugin
needs the `PATH` environment variable, add `PATH` to the `env` list in the
`plugins` collection.
```yaml
version: '2'
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
codegen:
- out: gen
plugin: test
plugins:
- name: test
env:
- PATH
wasm:
url: https://github.com/sqlc-dev/sqlc-gen-test/releases/download/v0.1.0/sqlc-gen-test.wasm
sha256: 138220eae508d4b65a5a8cea555edd155eb2290daf576b7a8b96949acfeb3790
```
A variable named `SQLC_VERSION` is always included in the plugin's
environment, set to the version of the `sqlc` executable invoking it.
================================================
FILE: docs/guides/privacy.md
================================================
# Privacy and data collection
These days, it feels like every piece of software is tracking you. From your
browser, to your phone, to your terminal, programs collect as much data about
you as possible and send it off to the cloud for analysis.
We believe the best way to keep data safe is to never collect it in the first
place.
## Our Privacy Pledge
The `sqlc` command line tool does not collect any information. It
does not send crash reports to a third-party. It does not gather anonymous
aggregate user behaviour analytics.
No analytics.
No finger-printing.
No tracking.
Not now and not in the future.
### Distribution Channels
We distribute sqlc using popular package managers such as
[Homebrew](https://brew.sh/) and [Snapcraft](https://snapcraft.io/). These
package managers and their associated command-line tools do collect usage
metrics.
We use these services to make it easy to for users to install sqlc. There will
always be an option to download sqlc from a stable URL.
## Hosted Services
We provide a few hosted services in addition to the sqlc command line tool.
### sqlc.dev
* Hosted on [GitHub Pages](https://pages.github.com/)
* Analytics with [Plausible](https://plausible.io/privacy-focused-web-analytics)
### docs.sqlc.dev
* Hosted on [Read the Docs](https://readthedocs.org/)
* Analytics with [Plausible](https://plausible.io/privacy-focused-web-analytics)
### play.sqlc.dev
* Hosted on [Heroku](https://heroku.com)
* Playground data stored in [Google Cloud Storage](https://cloud.google.com/storage)
* Automatically deleted after 30 days
### app.sqlc.dev / api.sqlc.dev
* Hosted on [Heroku](https://heroku.com)
* Error tracking and tracing with [Sentry](https://sentry.io)
================================================
FILE: docs/guides/using-go-and-pgx.rst
================================================
================
Using Go and pgx
================
.. note::
:code:`pgx/v5` is supported starting from v1.18.0.
pgx is a pure Go driver and toolkit for PostgreSQL. It's become the default
PostgreSQL package for many Gophers since lib/pq was put into maintenance mode.
^^^^^^^^^^^^^^^
Getting started
^^^^^^^^^^^^^^^
To start generating code that uses pgx, set the :code:`sql_package` field in
your :code:`sqlc.yaml` configuration file. Valid options are :code:`pgx/v4` or
:code:`pgx/v5`
.. code-block:: yaml
version: "2"
sql:
- engine: "postgresql"
queries: "query.sql"
schema: "query.sql"
gen:
go:
package: "db"
sql_package: "pgx/v5"
out: "db"
If you don't have an existing sqlc project on hand, create a directory with the
configuration file above and the following :code:`query.sql` file.
.. code-block:: sql
CREATE TABLE authors (
id BIGSERIAL PRIMARY KEY,
name text NOT NULL,
bio text
);
-- name: GetAuthor :one
SELECT * FROM authors
WHERE id = $1 LIMIT 1;
-- name: ListAuthors :many
SELECT * FROM authors
ORDER BY name;
-- name: CreateAuthor :one
INSERT INTO authors (
name, bio
) VALUES (
$1, $2
)
RETURNING *;
-- name: DeleteAuthor :exec
DELETE FROM authors
WHERE id = $1;
Generating the code will now give you pgx-compatible database access methods.
.. code-block:: bash
sqlc generate
^^^^^^^^^^^^^^^^^^^^^^^^^^
Generated code walkthrough
^^^^^^^^^^^^^^^^^^^^^^^^^^
The generated code is very similar to the code generated when using
:code:`lib/pq`. However, instead of using :code:`database/sql`, the code uses
pgx types directly.
.. code-block:: go
package main
import (
"context"
"fmt"
"os"
"github.com/jackc/pgx/v5"
"example.com/sqlc-tutorial/db"
)
func main() {
// urlExample := "postgres://username:password@localhost:5432/database_name"
conn, err := pgx.Connect(context.Background(), os.Getenv("DATABASE_URL"))
if err != nil {
fmt.Fprintf(os.Stderr, "Unable to connect to database: %v\n", err)
os.Exit(1)
}
defer conn.Close(context.Background())
q := db.New(conn)
author, err := q.GetAuthor(context.Background(), 1)
if err != nil {
fmt.Fprintf(os.Stderr, "GetAuthor failed: %v\n", err)
os.Exit(1)
}
fmt.Println(author.Name)
}
.. note::
For production applications, consider using pgxpool for connection pooling:
.. code-block:: go
import (
"github.com/jackc/pgx/v5/pgxpool"
"example.com/sqlc-tutorial/db"
)
func main() {
pool, err := pgxpool.New(context.Background(), os.Getenv("DATABASE_URL"))
if err != nil {
fmt.Fprintf(os.Stderr, "Unable to create connection pool: %v\n", err)
os.Exit(1)
}
defer pool.Close()
q := db.New(pool)
// Use q the same way as with single connections
}
================================================
FILE: docs/howto/ci-cd.md
================================================
# Using sqlc in CI/CD
If your project has more than a single developer, we suggest running `sqlc` as
part of your CI/CD pipeline. The four subcommands you'll want to run are `diff`,
`vet`, `verify` and `push`
`sqlc diff` ensures that your generated code is up to date. New developers to a
project may forget to run `sqlc generate` after adding a query or updating a
schema. They also might edit generated code. `sqlc diff` will catch both errors
by comparing the expected output from `sqlc generate` to what's on disk.
```diff
% sqlc diff
--- a/postgresql/query.sql.go
+++ b/postgresql/query.sql.go
@@ -55,7 +55,7 @@
const listAuthors = `-- name: ListAuthors :many
SELECT id, name, bio FROM authors
-ORDER BY name
+ORDER BY bio
`
```
`sqlc vet` runs a set of lint rules against your SQL queries. These rules are
helpful in catching anti-patterns before they make it into production. Please
see the [vet](vet.md) documentation for a complete guide to adding lint rules
for your project.
`sqlc verify` ensures that schema changes do not break production. Existing
queries are checked against new schema changes for correctness. Please see the
[verify](verify.md) documentation for a complete guide.
`sqlc push` pushes your database schema, queries and configuration to sqlc
Cloud. These archives are used by `verify` to catch breaking changes to your
database schema. Learn more about uploading projects [here](push.md)
## General setup
Install `sqlc` using the [suggested instructions](../overview/install).
Create three steps in your pipeline for `sqlc diff`, `sqlc vet`, and `sqlc
verify`. Run `sqlc push` after merge on your `main` branch.
## GitHub Actions
We provide the [setup-sqlc](https://github.com/marketplace/actions/setup-sqlc)
GitHub Action to install `sqlc`. The action uses the built-in
[tool-cache](https://github.com/actions/toolkit/blob/main/packages/tool-cache/README.md)
to speed up the installation process.
### diff
The following GitHub Workflow configuration runs `sqlc diff` on every push.
```yaml
name: sqlc
on: [push]
jobs:
diff:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: sqlc-dev/setup-sqlc@v3
with:
sqlc-version: '1.30.0'
- run: sqlc diff
```
### vet
The following GitHub Workflow configuration runs [sqlc vet](vet.md) on every push.
You can use `sqlc vet` without a database connection, but you'll need one if your
`sqlc` configuration references the built-in `sqlc/db-prepare` lint rule.
```yaml
name: sqlc
on: [push]
jobs:
vet:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: sqlc-dev/setup-sqlc@v3
with:
sqlc-version: '1.30.0'
# Start a PostgreSQL server
- uses: sqlc-dev/action-setup-postgres@master
with:
postgres-version: "16"
id: postgres
- run: sqlc vet
env:
POSTGRESQL_SERVER_URI: ${{ steps.postgres.outputs.connection-uri }}?sslmode=disable
```
### push
```{note}
Pushing a project is powered by [sqlc Cloud](https://dashboard.sqlc.dev). Sign up for [free](https://dashboard.sqlc.dev) today.
```
The following GitHub Workflow configuration runs [sqlc push](push.md) on
every push to `main`. Create an auth token via the
[dashboard](https://dashboard.sqlc.dev).
```yaml
name: sqlc
on: [push]
jobs:
push:
runs-on: ubuntu-latest
if: ${{ github.ref == 'refs/heads/main' }}
steps:
- uses: actions/checkout@v3
- uses: sqlc-dev/setup-sqlc@v3
with:
sqlc-version: '1.30.0'
- run: sqlc push
env:
SQLC_AUTH_TOKEN: ${{ secrets.SQLC_AUTH_TOKEN }}
```
### verify
```{note}
Verify database migrations is powered by [sqlc Cloud](https://dashboard.sqlc.dev). Sign up for [free](https://dashboard.sqlc.dev) today.
```
```yaml
name: sqlc
on: [push]
jobs:
verify:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: sqlc-dev/setup-sqlc@v3
with:
sqlc-version: '1.30.0'
- uses: sqlc-dev/action-setup-postgres@master
with:
postgres-version: "16"
id: postgres
- run: sqlc verify
env:
POSTGRESQL_SERVER_URI: ${{ steps.postgres.outputs.connection-uri }}?sslmode=disable
SQLC_AUTH_TOKEN: ${{ secrets.SQLC_AUTH_TOKEN }}
push:
runs-on: ubuntu-latest
if: ${{ github.ref == 'refs/heads/main' }}
steps:
- uses: sqlc-dev/setup-sqlc@v3
with:
sqlc-version: '1.30.0'
- run: sqlc push
env:
SQLC_AUTH_TOKEN: ${{ secrets.SQLC_AUTH_TOKEN }}
``````
================================================
FILE: docs/howto/ddl.md
================================================
# Modifying the database schema
sqlc parses `CREATE TABLE` and `ALTER TABLE` statements in order to generate
the necessary code.
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
birth_year int NOT NULL
);
ALTER TABLE authors ADD COLUMN bio text NOT NULL;
ALTER TABLE authors DROP COLUMN birth_year;
ALTER TABLE authors RENAME TO writers;
```
```go
package db
type Writer struct {
ID int
Bio string
}
```
## Handling SQL migrations
sqlc does not perform database migrations for you. However, sqlc is able to
differentiate between up and down migrations. sqlc ignores down migrations when
parsing SQL files.
sqlc supports parsing migrations from the following tools:
- [atlas](https://github.com/ariga/atlas)
- [dbmate](https://github.com/amacneil/dbmate)
- [golang-migrate](https://github.com/golang-migrate/migrate)
- [goose](https://github.com/pressly/goose)
- [sql-migrate](https://github.com/rubenv/sql-migrate)
- [tern](https://github.com/jackc/tern)
To enable migration parsing, specify the migration directory instead of a schema file:
```yaml
version: "2"
sql:
- engine: "postgresql"
queries: "query.sql"
schema: "db/migrations"
gen:
go:
package: "tutorial"
out: "tutorial"
```
### atlas
```sql
-- Create "post" table
CREATE TABLE "public"."post" ("id" integer NOT NULL, "title" text NULL, "body" text NULL, PRIMARY KEY ("id"));
```
```go
package db
type Post struct {
ID int
Title sql.NullString
Body sql.NullString
}
```
### dbmate
```sql
-- migrate:up
CREATE TABLE foo (bar INT NOT NULL);
-- migrate:down
DROP TABLE foo;
```
```go
package db
type Foo struct {
Bar int32
}
```
### golang-migrate
**Warning:**
[golang-migrate interprets](https://github.com/golang-migrate/migrate/blob/master/MIGRATIONS.md#migration-filename-format)
migration filenames numerically. However, sqlc parses migration files in
lexicographic order. If you choose to have sqlc enumerate your migration files,
make sure their numeric ordering matches their lexicographic ordering to avoid
unexpected behavior. This can be done by prepending enough zeroes to the
migration filenames.
This doesn't work as intended.
```
1_initial.up.sql
...
9_foo.up.sql
# this migration file will be parsed BEFORE 9_foo
10_bar.up.sql
```
This worked as intended.
```
001_initial.up.sql
...
009_foo.up.sql
010_bar.up.sql
```
In `20060102.up.sql`:
```sql
CREATE TABLE post (
id int NOT NULL,
title text,
body text,
PRIMARY KEY(id)
);
```
In `20060102.down.sql`:
```sql
DROP TABLE post;
```
```go
package db
type Post struct {
ID int
Title sql.NullString
Body sql.NullString
}
```
### goose
**Warning:**
sqlc parses migration files in lexicographic order. **If you are using numeric filenames for migrations in Goose and you choose to have sqlc enumerate your migration files**,
make sure their numeric ordering matches their lexicographic ordering to avoid
unexpected behavior. This can be done by prepending enough zeroes to the
migration filenames.
This doesn't work as intended.
```
1_initial.sql
...
9_foo.sql
# this migration file will be parsed BEFORE 9_foo
10_bar.sql
```
This worked as intended.
```
001_initial.sql
...
009_foo.sql
010_bar.sql
```
```sql
-- +goose Up
CREATE TABLE post (
id int NOT NULL,
title text,
body text,
PRIMARY KEY(id)
);
-- +goose Down
DROP TABLE post;
```
```go
package db
type Post struct {
ID int
Title sql.NullString
Body sql.NullString
}
```
### sql-migrate
```sql
-- +migrate Up
-- SQL in section 'Up' is executed when this migration is applied
CREATE TABLE people (id int);
-- +migrate Down
-- SQL section 'Down' is executed when this migration is rolled back
DROP TABLE people;
```
```go
package db
type People struct {
ID int32
}
```
### tern
```sql
CREATE TABLE comment (id int NOT NULL, text text NOT NULL);
---- create above / drop below ----
DROP TABLE comment;
```
```go
package db
type Comment struct {
ID int32
Text string
}
```
================================================
FILE: docs/howto/delete.md
================================================
# Deleting rows
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL
);
```
The parameter syntax varies by database engine:
**PostgreSQL:**
```sql
-- name: DeleteAuthor :exec
DELETE FROM authors WHERE id = $1;
```
**MySQL and SQLite:**
```sql
-- name: DeleteAuthor :exec
DELETE FROM authors WHERE id = ?;
```
```go
package db
import (
"context"
"database/sql"
)
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const deleteAuthor = `-- name: DeleteAuthor :exec
DELETE FROM authors WHERE id = $1
`
func (q *Queries) DeleteAuthor(ctx context.Context, id int) error {
_, err := q.db.ExecContext(ctx, deleteAuthor, id)
return err
}
```
================================================
FILE: docs/howto/embedding.md
================================================
#### Embedding structs
Embedding allows you to reuse existing model structs in more queries, resulting
in less manual serialization work. First, imagine we have the following schema
with students and test scores.
```sql
CREATE TABLE students (
id bigserial PRIMARY KEY,
name text NOT NULL,
age integer NOT NULL
);
CREATE TABLE test_scores (
student_id bigint NOT NULL,
score integer NOT NULL,
grade text NOT NULL
);
```
We want to select the student record and the scores they got on a test.
Here's how we'd usually do that:
```sql
-- name: ScoreAndTests :many
SELECT students.*, test_scores.*
FROM students
JOIN test_scores ON test_scores.student_id = students.id
WHERE students.id = $1;
```
When using Go, sqlc will produce a struct like this:
```go
type ScoreAndTestsRow struct {
ID int64
Name string
Age int32
StudentID int64
Score int32
Grade string
}
```
With embedding, the struct will contain a model for both tables instead of a
flattened list of columns.
```sql
-- name: ScoreAndTests :many
SELECT sqlc.embed(students), sqlc.embed(test_scores)
FROM students
JOIN test_scores ON test_scores.student_id = students.id
WHERE students.id = $1;
```
```
type ScoreAndTestsRow struct {
Student Student
TestScore TestScore
}
```
================================================
FILE: docs/howto/generate.md
================================================
# `generate` - Generating code
`sqlc generate` parses SQL, analyzes the results, and outputs code. Your schema and queries are stored in separate SQL files. The paths to these files live in a `sqlc.yaml` configuration file.
```yaml
version: "2"
sql:
- engine: "postgresql"
queries: "query.sql"
schema: "schema.sql"
gen:
go:
package: "tutorial"
out: "tutorial"
sql_package: "pgx/v5"
```
We've written extensive docs on [retrieving](select.md), [inserting](insert.md),
[updating](update.md), and [deleting](delete.md) rows.
By default, sqlc runs its analysis using a built-in query analysis engine. While fast, this engine can't handle some complex queries and type-inference.
You can configure sqlc to use a database connection for enhanced analysis using metadata from that database.
The database-backed analyzer currently supports PostgreSQL, with [MySQL](https://github.com/sqlc-dev/sqlc/issues/2902) and [SQLite](https://github.com/sqlc-dev/sqlc/issues/2903)
support planned in the future.
## Enhanced analysis with managed databases
With [managed databases](managed-databases.md) configured, `generate` will automatically create a hosted ephemeral database with your
schema and use that database to improve its query analysis. And sqlc will cache its analysis locally
on a per-query basis to speed up future `generate` runs. This saves you the trouble of running and maintaining a database with
an up-to-date schema. Here's a minimal working configuration:
```yaml
version: "2"
servers:
- engine: postgresql
uri: "postgres://locahost:5432/postgres?sslmode=disable"
sql:
- engine: "postgresql"
queries: "query.sql"
schema: "schema.sql"
database:
managed: true
gen:
go:
out: "db"
sql_package: "pgx/v5"
```
## Enhanced analysis using your own database
You can opt-in to database-backed analysis using your own database, by providing a `uri` in your sqlc
[database](../reference/config.md#database) configuration.
The `uri` string can contain references to environment variables using the `${...}`
syntax. In the following example, the connection string will have the value of
the `PG_PASSWORD` environment variable set as its password.
```yaml
version: "2"
sql:
- engine: "postgresql"
queries: "query.sql"
schema: "schema.sql"
database:
uri: "postgres://postgres:${PG_PASSWORD}@localhost:5432/postgres"
gen:
go:
out: "db"
sql_package: "pgx/v5"
```
Databases configured with a `uri` must have an up-to-date schema for query analysis to work correctly, and `sqlc` does not apply schema migrations your database. Use your migration tool of choice to create the necessary
tables and objects before running `sqlc generate`.
================================================
FILE: docs/howto/insert.md
================================================
# Inserting rows
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL
);
```
The parameter syntax varies by database engine:
**PostgreSQL:**
```sql
-- name: CreateAuthor :exec
INSERT INTO authors (bio) VALUES ($1);
```
**MySQL and SQLite:**
```sql
-- name: CreateAuthor :exec
INSERT INTO authors (bio) VALUES (?);
```
```go
package db
import (
"context"
"database/sql"
)
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const createAuthor = `-- name: CreateAuthor :exec
INSERT INTO authors (bio) VALUES ($1)
`
func (q *Queries) CreateAuthor(ctx context.Context, bio string) error {
_, err := q.db.ExecContext(ctx, createAuthor, bio)
return err
}
```
## Returning columns from inserted rows
sqlc has full support for the `RETURNING` statement.
```sql
-- Example queries for sqlc
CREATE TABLE authors (
id BIGSERIAL PRIMARY KEY,
name text NOT NULL,
bio text
);
```
**PostgreSQL:**
```sql
-- name: CreateAuthor :one
INSERT INTO authors (
name, bio
) VALUES (
$1, $2
)
RETURNING *;
-- name: CreateAuthorAndReturnId :one
INSERT INTO authors (
name, bio
) VALUES (
$1, $2
)
RETURNING id;
```
**SQLite (with RETURNING support):**
```sql
-- name: CreateAuthor :one
INSERT INTO authors (
name, bio
) VALUES (
?, ?
)
RETURNING *;
-- name: CreateAuthorAndReturnId :one
INSERT INTO authors (
name, bio
) VALUES (
?, ?
)
RETURNING id;
```
Note: MySQL does not support the `RETURNING` clause. Use `:execresult` instead to get the last insert ID.
```go
package db
import (
"context"
"database/sql"
)
const createAuthor = `-- name: CreateAuthor :one
INSERT INTO authors (
name, bio
) VALUES (
$1, $2
)
RETURNING id, name, bio
`
type CreateAuthorParams struct {
Name string
Bio sql.NullString
}
func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorParams) (Author, error) {
row := q.db.QueryRowContext(ctx, createAuthor, arg.Name, arg.Bio)
var i Author
err := row.Scan(&i.ID, &i.Name, &i.Bio)
return i, err
}
const createAuthorAndReturnId = `-- name: CreateAuthorAndReturnId :one
INSERT INTO authors (
name, bio
) VALUES (
$1, $2
)
RETURNING id
`
type CreateAuthorAndReturnIdParams struct {
Name string
Bio sql.NullString
}
func (q *Queries) CreateAuthorAndReturnId(ctx context.Context, arg CreateAuthorAndReturnIdParams) (int64, error) {
row := q.db.QueryRowContext(ctx, createAuthorAndReturnId, arg.Name, arg.Bio)
var id int64
err := row.Scan(&id)
return id, err
}
```
## Using CopyFrom
### PostgreSQL
PostgreSQL supports the [COPY protocol](https://www.postgresql.org/docs/current/sql-copy.html) that can insert rows a lot faster than sequential inserts. You can use this easily with sqlc:
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
name text NOT NULL,
bio text NOT NULL
);
-- name: CreateAuthors :copyfrom
INSERT INTO authors (name, bio) VALUES ($1, $2);
```
```go
type CreateAuthorsParams struct {
Name string
Bio string
}
func (q *Queries) CreateAuthors(ctx context.Context, arg []CreateAuthorsParams) (int64, error) {
...
}
```
The `:copyfrom` command requires either `pgx/v4` or `pgx/v5`.
```yaml
version: "2"
sql:
- engine: "postgresql"
queries: "query.sql"
schema: "query.sql"
gen:
go:
package: "db"
sql_package: "pgx/v5"
out: "db"
```
### MySQL
MySQL supports a similar feature using [LOAD DATA](https://dev.mysql.com/doc/refman/8.0/en/load-data.html).
Errors and duplicate keys are treated as warnings and insertion will
continue, even without an error for some cases. Use this in a transaction
and use SHOW WARNINGS to check for any problems and roll back if necessary.
Check the [error handling](https://dev.mysql.com/doc/refman/8.0/en/load-data.html#load-data-error-handling) documentation for more information.
```sql
CREATE TABLE foo (a text, b integer, c DATETIME, d DATE);
-- name: InsertValues :copyfrom
INSERT INTO foo (a, b, c, d) VALUES (?, ?, ?, ?);
```
```go
func (q *Queries) InsertValues(ctx context.Context, arg []InsertValuesParams) (int64, error) {
...
}
```
The `:copyfrom` command requires setting the `sql_package` and `sql_driver` options.
```yaml
version: "2"
sql:
- engine: "mysql"
queries: "query.sql"
schema: "query.sql"
gen:
go:
package: "db"
sql_package: "database/sql"
sql_driver: "github.com/go-sql-driver/mysql"
out: "db"
```
================================================
FILE: docs/howto/managed-databases.md
================================================
# Managed databases
*Added in v1.22.0*
`sqlc` can automatically create read-only databases to power query analysis,
linting and verification. These databases are immediately useful for powering
sqlc's database-connected query analyzer, an opt-in feature that improves upon
sqlc's built-in query analysis engine. PostgreSQL support is available today,
with MySQL on the way.
Once configured, `sqlc` will also use managed databases when linting queries
with [`sqlc vet`](vet.md) in cases where your lint rules require a connection
to a running database.
Managed databases are under active development, and we're interested in
supporting other use-cases.
## Configuring managed databases
To configure `sqlc` to use managed databases, remove the `uri` key from your
`database` configuration and replace it with the `managed` key set to `true`.
Access to a running database server is required. Add a connection string to the `servers` mapping.
```yaml
version: '2'
servers:
- engine: postgresql
uri: "postgres://localhost:5432/postgres?sslmode=disable"
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
database:
managed: true
```
An environment variable can also be used via the `${}` syntax.
```yaml
version: '2'
servers:
- engine: postgresql
uri: ${DATABASE_URI}
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
database:
managed: true
```
## Improving codegen
Without a database connection, sqlc does its best to parse, analyze and compile your queries just using
the schema you pass it and what it knows about the various database engines it supports. In many cases
this works just fine, but for more advanced queries sqlc might not have enough information to produce good code.
With managed databases configured, `sqlc generate` will automatically create a hosted ephemeral database with your
schema and use that database to improve its query analysis. And sqlc will cache its analysis locally
on a per-query basis to speed up future codegen runs. Here's a minimal working configuration:
```yaml
version: '2'
servers:
- engine: postgresql
uri: "postgres://localhost:5432/postgres?sslmode=disable"
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
database:
managed: true
gen:
go:
out: "db"
```
## Linting queries
With managed databases configured, `sqlc vet` will automatically create a hosted ephemeral database with your
schema and use that database when running lint rules that require a
database connection, e.g. any [rule relying on `EXPLAIN ...` output](vet.md#rules-using-explain-output).
If you don't yet have any vet rules, the [built-in sqlc/db-prepare rule](vet.md#sqlc-db-prepare)
is a good place to start. It prepares each of your queries against the database
to ensure the query is valid. Here's a minimal working configuration:
```yaml
version: '2'
servers:
- engine: postgresql
uri: "postgres://localhost:5432/postgres?sslmode=disable"
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
database:
managed: true
rules:
- sqlc/db-prepare
```
================================================
FILE: docs/howto/named_parameters.md
================================================
# Naming parameters
sqlc tries to generate good names for positional parameters, but sometimes it
lacks enough context. The following SQL generates parameters with less than
ideal names:
```sql
-- name: UpsertAuthorName :one
UPDATE author
SET
name = CASE WHEN $1::bool
THEN $2::text
ELSE name
END
RETURNING *;
```
```go
type UpdateAuthorNameParams struct {
Column1 bool `json:""`
Column2_2 string `json:"_2"`
}
```
In these cases, named parameters give you the control over field names on the
Params struct.
```sql
-- name: UpsertAuthorName :one
UPDATE author
SET
name = CASE WHEN sqlc.arg(set_name)::bool
THEN sqlc.arg(name)::text
ELSE name
END
RETURNING *;
```
```go
type UpdateAuthorNameParams struct {
SetName bool `json:"set_name"`
Name string `json:"name"`
}
```
If the `sqlc.arg()` syntax is too verbose for your taste, you can use the `@`
operator as a shortcut.
```{note}
The `@` operator as a shortcut for `sqlc.arg()` is not supported in MySQL.
```
```sql
-- name: UpsertAuthorName :one
UPDATE author
SET
name = CASE WHEN @set_name::bool
THEN @name::text
ELSE name
END
RETURNING *;
```
## Nullable parameters
sqlc infers the nullability of any specified parameters, and often does exactly
what you want. If you want finer control over the nullability of your
parameters, you may use `sqlc.narg()` (**n**ullable arg) to override the default
behavior. Using `sqlc.narg` tells sqlc to ignore whatever nullability it has
inferred and generate a nullable parameter instead. There is no nullable
equivalent of the `@` syntax.
Here is an example that uses a single query to allow updating an author's
name, bio or both.
```sql
-- name: UpdateAuthor :one
UPDATE author
SET
name = coalesce(sqlc.narg('name'), name),
bio = coalesce(sqlc.narg('bio'), bio)
WHERE id = sqlc.arg('id')
RETURNING *;
```
The following code is generated:
```go
type UpdateAuthorParams struct {
Name sql.NullString
Bio sql.NullString
ID int64
}
```
================================================
FILE: docs/howto/overrides.md
================================================
# Overriding types
:::{note}
Type overrides and field renaming are only fully-supported for Go.
:::
In many cases it's useful to tell `sqlc` explicitly what Go type you want it to
use for a query input or output. For instance, by default when you use
`pgx/v5`, `sqlc` will map a PostgreSQL UUID type to `UUID` from `github.com/jackc/pgx/pgtype`.
But you may want `sqlc` to use `UUID` from `github.com/google/uuid` instead.
To tell `sqlc` to use a different Go type, add an entry to the `overrides` list in your
configuration.
`sqlc` offers two kinds of Go type overrides:
* `db_type` overrides, which override the Go type for a specific database type.
* `column` overrides, which override the Go type for a column or columns by name.
Here's an example including one of each kind:
```yaml
version: "2"
sql:
- schema: "postgresql/schema.sql"
queries: "postgresql/query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
sql_package: "pgx/v5"
overrides:
- db_type: "uuid"
nullable: true
go_type:
import: "github.com/google/uuid"
type: "UUID"
- column: "users.birthday"
go_type: "time.Time"
```
:::{tip}
A single `db_type` override configuration applies to either nullable or non-nullable
columns, but not both. If you want the same Go type to override regardless of
nullability, you'll need to configure two overrides: one with `nullable: true` and one without.
:::
## The `overrides` list
Each element in the `overrides` list has the following keys:
- `db_type`:
- A database type to override. Find the full list of supported types in [postgresql_type.go](https://github.com/sqlc-dev/sqlc/blob/main/internal/codegen/golang/postgresql_type.go#L12) or [mysql_type.go](https://github.com/sqlc-dev/sqlc/blob/main/internal/codegen/golang/mysql_type.go#L12). Note that for Postgres you must use pg_catalog-prefixed names where available. `db_type` and `column` are mutually exclusive.
- `column`:
- A column name to override. The value should be of the form `table.column` but you can also specify `schema.table.column` or `catalog.schema.table.column`. `column` and `db_type` are mutually exclusive.
- `go_type`:
- The fully-qualified name of a Go type to use in generated code. This is usually a string but can also be [a map](#the-go-type-map) for more complex configurations.
- `go_struct_tag`:
- A reflect-style struct tag to use in generated code, e.g. `a:"b" x:"y,z"`.
If you want `json` or `db` tags for all fields, configure `emit_json_tags` or `emit_db_tags` instead.
- `unsigned`:
- If `true`, sqlc will apply this override when a numeric column is unsigned.
Note that this only applies to `db_type` overrides and has no effect on `column` overrides.
Defaults to `false`.
- `nullable`:
- If `true`, sqlc will apply this override when a column is nullable.
Otherwise `sqlc` will apply this override when a column is non-nullable.
Note that this only applies to `db_type` overrides and has no effect on `column` overrides.
Defaults to `false`.
:::{tip}
A single `db_type` override configuration applies to either nullable or non-nullable
columns, but not both. If you want the same Go type to override regardless of nullability, you'll
need to configure two overrides: one with `nullable: true` and one without.
:::
:::{note}
When generating code, `column` override configurations take precedence over `db_type` configurations.
:::
### The `go_type` map
Some overrides may require more detailed configuration. If necessary, `go_type`
can be a map with the following keys:
- `import`:
- The import path for the package where the type is defined.
- `package`:
- The package name where the type is defined. This should only be necessary when your import path doesn't end with the desired package name.
- `type`:
- The type name itself, without any package prefix.
- `pointer`:
- If `true`, generated code will use a pointer to the type rather than the type itself.
- `slice`:
- If `true`, generated code will use a slice of the type rather than the type itself.
An example:
```yaml
version: "2"
sql:
- schema: "postgresql/schema.sql"
queries: "postgresql/query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
sql_package: "pgx/v5"
overrides:
- db_type: "uuid"
go_type:
import: "a/b/v2"
package: "b"
type: "MyType"
pointer: true
```
## Global overrides
To override types in all packages that `sqlc` generates, add an override
configuration to the top-level `overrides` section of your `sqlc` config:
```yaml
version: "2"
overrides:
go:
overrides:
- db_type: "pg_catalog.timestamptz"
nullable: true
engine: "postgresql"
go_type:
import: "gopkg.in/guregu/null.v4"
package: "null"
type: "Time"
sql:
- schema: "service1/schema.sql"
queries: "service1/query.sql"
engine: "postgresql"
gen:
go:
package: "service1"
out: "service1"
- schema: "service2/schema.sql"
queries: "service2/query.sql"
engine: "postgresql"
gen:
go:
package: "service2"
out: "service2"
```
Using this configuration, whenever there is a nullable `timestamp with time zone`
column in a Postgres table, `sqlc` will generate Go code using `null.Time`.
Note that the mapping for global type overrides has a field called `engine` that
is absent in per-package type overrides. This field is only used when there are
multiple `sql` sections using different engines. If you're only generating code
for a single database engine you can omit it.
#### Version 1 configuration
If you are using the older version 1 of the `sqlc` configuration format, override
configurations themselves are unchanged but are nested differently.
Per-package configurations are nested under the `overrides` key within an item
in the `packages` list:
```yaml
version: "1"
packages:
- name: "db"
path: "internal/db"
queries: "./sql/query/"
schema: "./sql/schema/"
engine: "postgresql"
overrides: [...]
```
And global configurations are nested under the top-level `overrides` key:
```yaml
version: "1"
packages: [...]
overrides:
- db_type: "uuid"
go_type: "github.com/gofrs/uuid.UUID"
```
================================================
FILE: docs/howto/prepared_query.md
================================================
# Preparing queries
If you're using `pgx/v5` you get its
[implicit support](https://github.com/jackc/pgx/wiki/Automatic-Prepared-Statement-Caching)
for prepared statements. No additional `sqlc` configuration is required.
For other drivers, `sqlc` can give you the option to explicitly use prepared
queries. These prepared queries also work with transactions.
You'll need to set `emit_prepared_queries` to `true` in your `sqlc` configuration
to generate code similar to the example below.
```sql
CREATE TABLE records (
id SERIAL PRIMARY KEY
);
-- name: GetRecord :one
SELECT * FROM records
WHERE id = $1;
```
```go
package db
import (
"context"
"database/sql"
"fmt"
)
type Record struct {
ID int32
}
type DBTX interface {
PrepareContext(context.Context, string) (*sql.Stmt, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
func Prepare(ctx context.Context, db DBTX) (*Queries, error) {
q := Queries{db: db}
var err error
if q.getRecordStmt, err = db.PrepareContext(ctx, getRecord); err != nil {
return nil, fmt.Errorf("error preparing query GetRecord: %w", err)
}
return &q, nil
}
func (q *Queries) queryRow(ctx context.Context, stmt *sql.Stmt, query string, args ...interface{}) *sql.Row {
switch {
case stmt != nil && q.tx != nil:
return q.tx.StmtContext(ctx, stmt).QueryRowContext(ctx, args...)
case stmt != nil:
return stmt.QueryRowContext(ctx, args...)
default:
return q.db.QueryRowContext(ctx, query, args...)
}
}
type Queries struct {
db DBTX
tx *sql.Tx
getRecordStmt *sql.Stmt
}
func (q *Queries) WithTx(tx *sql.Tx) *Queries {
return &Queries{
db: tx,
tx: tx,
getRecordStmt: q.getRecordStmt,
}
}
const getRecord = `-- name: GetRecord :one
SELECT id FROM records
WHERE id = $1
`
func (q *Queries) GetRecord(ctx context.Context, id int32) (int32, error) {
row := q.queryRow(ctx, q.getRecordStmt, getRecord, id)
err := row.Scan(&id)
return id, err
}
```
================================================
FILE: docs/howto/push.md
================================================
# `push` - Uploading projects
```{note}
`push` is powered by [sqlc Cloud](https://dashboard.sqlc.dev). Sign up for [free](https://dashboard.sqlc.dev) today.
```
*Added in v1.24.0*
We've renamed the `upload` sub-command to `push`. We've also changed the data sent along in a push request. Upload used to include the configuration file, migrations, queries, and all generated code. Push drops the generated code in favor of including the [plugin.GenerateRequest](https://buf.build/sqlc/sqlc/docs/main:plugin#plugin.GenerateRequest), which is the protocol buffer message we pass to codegen plugins.
## Add configuration
After creating a project, add the project ID to your sqlc configuration file.
```yaml
version: "2"
cloud:
project: "<PROJECT_ID>"
```
You'll also need to create an auth token and make it available via the
`SQLC_AUTH_TOKEN` environment variable.
```shell
export SQLC_AUTH_TOKEN=sqlc_xxxxxxxx
```
## Dry run
You can see what's included when uploading your project by using using the
`--dry-run` flag:
```shell
$ sqlc push --dry-run
2023/11/21 10:39:51 INFO config file=sqlc.yaml bytes=912
2023/11/21 10:39:51 INFO codegen_request queryset=app file=codegen_request.pb
2023/11/21 10:39:51 INFO schema queryset=app file=migrations/00001_initial.sql bytes=3033
2023/11/21 10:39:51 INFO query queryset=app file=queries/app.sql bytes=1150
```
The output is the files `sqlc` would have sent without the `--dry-run` flag.
## Push
Once you're ready to push, remove the `--dry-run` flag.
```shell
$ sqlc push
```
### Tags
You can provide tags to associate with a push, primarily as a convenient reference when using `sqlc verify` with the `against` argument.
Tags only refer to a single push, so if you pass an existing tag to `push` it will overwrite the previous reference.
```shell
$ sqlc push --tag main
```
### Annotations
Annotations are added to each push request. By default, we include these environment variables (if they are present).
```
GITHUB_REPOSITORY
GITHUB_REF
GITHUB_REF_NAME
GITHUB_REF_TYPE
GITHUB_SHA
```
================================================
FILE: docs/howto/query_count.md
================================================
# Counting rows
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
hometown text NOT NULL
);
-- name: CountAuthors :one
SELECT count(*) FROM authors;
-- name: CountAuthorsByTown :many
SELECT hometown, count(*) FROM authors
GROUP BY 1
ORDER BY 1;
```
```go
package db
import (
"context"
"database/sql"
)
type DBTX interface {
QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const countAuthors = `-- name: CountAuthors :one
SELECT count(*) FROM authors
`
func (q *Queries) CountAuthors(ctx context.Context) (int, error) {
row := q.db.QueryRowContext(ctx, countAuthors)
var i int
err := row.Scan(&i)
return i, err
}
const countAuthorsByTown = `-- name: CountAuthorsByTown :many
SELECT hometown, count(*) FROM authors
GROUP BY 1
ORDER BY 1
`
type CountAuthorsByTownRow struct {
Hometown string
Count int
}
func (q *Queries) CountAuthorsByTown(ctx context.Context) ([]CountAuthorsByTownRow, error) {
rows, err := q.db.QueryContext(ctx, countAuthorsByTown)
if err != nil {
return nil, err
}
defer rows.Close()
items := []CountAuthorsByTownRow{}
for rows.Next() {
var i CountAuthorsByTownRow
if err := rows.Scan(&i.Hometown, &i.Count); err != nil {
return nil, err
}
items = append(items, i)
}
if err := rows.Close(); err != nil {
return nil, err
}
if err := rows.Err(); err != nil {
return nil, err
}
return items, nil
}
```
================================================
FILE: docs/howto/rename.md
================================================
# Renaming fields
Struct field names are generated from column names using a simple algorithm:
split the column name on underscores and capitalize the first letter of each
part.
```
account -> Account
spotify_url -> SpotifyUrl
app_id -> AppID
```
If you're not happy with a field's generated name, use the `rename` mapping
to pick a new name. The keys are column names and the values are the struct
field name to use.
```yaml
version: "2"
sql:
- schema: "postgresql/schema.sql"
queries: "postgresql/query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "postgresql"
rename:
spotify_url: "SpotifyURL"
```
## Tables
The output structs associated with tables can also be renamed. By default,
the struct name will be the singular version of the table name. For example,
the `authors` table will generate an `Author` struct and the `book_publishers`
table will generate a `BookPublisher` struct.
```sql
CREATE TABLE authors (
id BIGSERIAL PRIMARY KEY,
name text NOT NULL,
bio text
);
CREATE TABLE book_publishers (
id BIGSERIAL PRIMARY KEY,
name text NOT NULL
);
```
```go
package db
import (
"database/sql"
)
type Author struct {
ID int64
Name string
Bio sql.NullString
}
type Publisher struct {
ID int64
Name string
}
```
To rename these structs, you must use the generated struct name. In this
example, that would be `author` and `book_publisher`. Use the `rename` map to
change the name of these struct to `Writer` and `BookPublisher` (note the
camel-casing and the underscore for multi-worded tables).
```yaml
version: '1'
packages:
- path: db
engine: postgresql
schema: query.sql
queries: query.sql
rename:
author: Writer
book_publisher: Publisher
```
```yaml
version: "2"
sql:
- engine: postgresql
queries: query.sql
schema: query.sql
overrides:
go:
rename:
author: Writer
book_publisher: Publisher
```
```go
package db
import (
"database/sql"
)
type Writer struct {
ID int64
Name string
Bio sql.NullString
}
type Publisher struct {
ID int64
Name string
}
```
## Limitations
Rename mappings apply to an entire package. Therefore, a column named `foo` and
a table name `foo` can't map to different rename values.
================================================
FILE: docs/howto/select.md
================================================
# Retrieving rows
To generate a database access method, annotate a query with a specific comment.
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL,
birth_year int NOT NULL
);
```
The parameter syntax varies by database engine:
**PostgreSQL:**
```sql
-- name: GetAuthor :one
SELECT * FROM authors
WHERE id = $1;
-- name: ListAuthors :many
SELECT * FROM authors
ORDER BY id;
```
**MySQL and SQLite:**
```sql
-- name: GetAuthor :one
SELECT * FROM authors
WHERE id = ?;
-- name: ListAuthors :many
SELECT * FROM authors
ORDER BY id;
```
A few new pieces of code are generated beyond the `Author` struct. An interface
for the underlying database is generated. The `*sql.DB` and `*sql.Tx` types
satisfy this interface.
The database access methods are added to a `Queries` struct, which is created
using the `New` method.
Note that the `*` in our query has been replaced with explicit column names.
This change ensures that the query will never return unexpected data.
Our query was annotated with `:one`, meaning that it should only return a
single row. We scan the data from that one into a `Author` struct.
Since the get query has a single parameter, the `GetAuthor` method takes a single
`int` as an argument.
Since the list query has no parameters, the `ListAuthors` method accepts no
arguments.
```go
package db
import (
"context"
"database/sql"
)
type Author struct {
ID int
Bio string
BirthYear int
}
type DBTX interface {
QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const getAuthor = `-- name: GetAuthor :one
SELECT id, bio, birth_year FROM authors
WHERE id = $1
`
func (q *Queries) GetAuthor(ctx context.Context, id int) (Author, error) {
row := q.db.QueryRowContext(ctx, getAuthor, id)
var i Author
err := row.Scan(&i.ID, &i.Bio, &i.BirthYear)
return i, err
}
const listAuthors = `-- name: ListAuthors :many
SELECT id, bio, birth_year FROM authors
ORDER BY id
`
func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
rows, err := q.db.QueryContext(ctx, listAuthors)
if err != nil {
return nil, err
}
defer rows.Close()
var items []Author
for rows.Next() {
var i Author
if err := rows.Scan(&i.ID, &i.Bio, &i.BirthYear); err != nil {
return nil, err
}
items = append(items, i)
}
if err := rows.Close(); err != nil {
return nil, err
}
if err := rows.Err(); err != nil {
return nil, err
}
return items, nil
}
```
## Selecting columns
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL,
birth_year int NOT NULL
);
-- name: GetBioForAuthor :one
SELECT bio FROM authors
WHERE id = $1;
-- name: GetInfoForAuthor :one
SELECT bio, birth_year FROM authors
WHERE id = $1;
```
When selecting a single column, only that value is returned. The `GetBioForAuthor`
method takes a single `int` as an argument and returns a `string` and an
`error`.
When selecting multiple columns, a row record (method-specific struct) is
returned. In this case, `GetInfoForAuthor` returns a struct with two fields:
`Bio` and `BirthYear`.
If a query result has no row records, a zero value and an `ErrNoRows` error are
returned instead of a zero value and `nil`. For instance, when the `GetBioForAuthor`
result has no rows, it will return `""` and `ErrNoRows`.
```go
package db
import (
"context"
"database/sql"
)
type DBTX interface {
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const getBioForAuthor = `-- name: GetBioForAuthor :one
SELECT bio FROM authors
WHERE id = $1
`
func (q *Queries) GetBioForAuthor(ctx context.Context, id int) (string, error) {
row := q.db.QueryRowContext(ctx, getBioForAuthor, id)
var i string
err := row.Scan(&i)
return i, err
}
const getInfoForAuthor = `-- name: GetInfoForAuthor :one
SELECT bio, birth_year FROM authors
WHERE id = $1
`
type GetInfoForAuthorRow struct {
Bio string
BirthYear int
}
func (q *Queries) GetInfoForAuthor(ctx context.Context, id int) (GetInfoForAuthorRow, error) {
row := q.db.QueryRowContext(ctx, getInfoForAuthor, id)
var i GetInfoForAuthorRow
err := row.Scan(&i.Bio, &i.BirthYear)
return i, err
}
```
## Passing a slice as a parameter to a query
### PostgreSQL
In PostgreSQL,
[ANY](https://www.postgresql.org/docs/current/functions-comparisons.html#id-1.5.8.28.16)
allows you to check if a value exists in an array expression. Queries using ANY
with a single parameter will generate method signatures with slices as
arguments. Use the postgres data types, eg: int, varchar, etc.
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL,
birth_year int NOT NULL
);
-- name: ListAuthorsByIDs :many
SELECT * FROM authors
WHERE id = ANY($1::int[]);
```
The above SQL will generate the following code:
```go
package db
import (
"context"
"database/sql"
"github.com/lib/pq"
)
type Author struct {
ID int
Bio string
BirthYear int
}
type DBTX interface {
QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const listAuthors = `-- name: ListAuthorsByIDs :many
SELECT id, bio, birth_year FROM authors
WHERE id = ANY($1::int[])
`
func (q *Queries) ListAuthorsByIDs(ctx context.Context, ids []int) ([]Author, error) {
rows, err := q.db.QueryContext(ctx, listAuthors, pq.Array(ids))
if err != nil {
return nil, err
}
defer rows.Close()
var items []Author
for rows.Next() {
var i Author
if err := rows.Scan(&i.ID, &i.Bio, &i.BirthYear); err != nil {
return nil, err
}
items = append(items, i)
}
if err := rows.Close(); err != nil {
return nil, err
}
if err := rows.Err(); err != nil {
return nil, err
}
return items, nil
}
```
### MySQL and SQLite
MySQL and SQLite differ from PostgreSQL in that placeholders must be generated based on
the number of elements in the slice you pass in. Though trivial it is still
something of a nuisance. The passed in slice must not be nil or empty or an
error will be returned (ie not a panic). The placeholder insertion location is
marked by the meta-function `sqlc.slice()` (which is similar to `sqlc.arg()`
that you see documented under [Naming parameters](named_parameters.md)).
To rephrase, the `sqlc.slice('param')` behaves identically to `sqlc.arg()` it
terms of how it maps the explicit argument to the function signature, eg:
* `sqlc.slice('ids')` maps to `ids []GoType` in the function signature
* `sqlc.slice(cust_ids)` maps to `custIds []GoType` in the function signature
(like `sqlc.arg()`, the parameter does not have to be quoted)
This feature is not compatible with `emit_prepared_queries` statement found in the
[Configuration file](../reference/config.md).
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL,
birth_year int NOT NULL
);
-- name: ListAuthorsByIDs :many
SELECT * FROM authors
WHERE id IN (sqlc.slice('ids'));
```
The above SQL will generate the following code:
```go
package db
import (
"context"
"database/sql"
"fmt"
"strings"
)
type Author struct {
ID int
Bio string
BirthYear int
}
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
PrepareContext(context.Context, string) (*sql.Stmt, error)
QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
func (q *Queries) WithTx(tx *sql.Tx) *Queries {
return &Queries{
db: tx,
}
}
const listAuthorsByIDs = `-- name: ListAuthorsByIDs :many
SELECT id, bio, birth_year FROM authors
WHERE id IN (/*SLICE:ids*/?)
`
func (q *Queries) ListAuthorsByIDs(ctx context.Context, ids []int64) ([]Author, error) {
sql := listAuthorsByIDs
var queryParams []interface{}
if len(ids) == 0 {
return nil, fmt.Errorf("slice ids must have at least one element")
}
for _, v := range ids {
queryParams = append(queryParams, v)
}
sql = strings.Replace(sql, "/*SLICE:ids*/?", strings.Repeat(",?", len(ids))[1:], 1)
rows, err := q.db.QueryContext(ctx, sql, queryParams...)
if err != nil {
return nil, err
}
defer rows.Close()
var items []Author
for rows.Next() {
var i Author
if err := rows.Scan(&i.ID, &i.Bio, &i.BirthYear); err != nil {
return nil, err
}
items = append(items, i)
}
if err := rows.Close(); err != nil {
return nil, err
}
if err := rows.Err(); err != nil {
return nil, err
}
return items, nil
}
```
================================================
FILE: docs/howto/structs.md
================================================
# Configuring generated structs
## Naming scheme
Structs generated from tables will attempt to use the singular form of a table
name if the table name is pluralized.
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
name text NOT NULL
);
```
```go
package db
// Struct names use the singular form of table names
type Author struct {
ID int
Name string
}
```
## JSON tags
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
created_at timestamp NOT NULL
);
```
sqlc can generate structs with JSON tags by adding the `emit_json_tags` key to the configuration file as it shows on [configuration reference](../reference/config.md).
The JSON name for a field matches
the column name in the database.
```go
package db
import (
"time"
)
type Author struct {
ID int `json:"id"`
CreatedAt time.Time `json:"created_at"`
}
```
## More control
See the guide to [Overriding types](./overrides.md) for fine-grained control over struct field types and tags.
================================================
FILE: docs/howto/transactions.md
================================================
# Using transactions
In the code generated by sqlc, the `WithTx` method allows a `Queries` instance to be associated with a transaction.
For example, with the following SQL structure:
`schema.sql`:
```sql
CREATE TABLE records (
id SERIAL PRIMARY KEY,
counter INT NOT NULL
);
```
`query.sql`
```sql
-- name: GetRecord :one
SELECT * FROM records
WHERE id = $1;
-- name: UpdateRecord :exec
UPDATE records SET counter = $2
WHERE id = $1;
```
And the generated code from sqlc in `db.go`:
```go
package tutorial
import (
"context"
"database/sql"
)
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
PrepareContext(context.Context, string) (*sql.Stmt, error)
QueryContext(context.Context, string, ...interface{}) (*sql.Rows, error)
QueryRowContext(context.Context, string, ...interface{}) *sql.Row
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
func (q *Queries) WithTx(tx *sql.Tx) *Queries {
return &Queries{
db: tx,
}
}
```
You'd use it like this:
```go
// Using `github/lib/pq` as the driver.
func bumpCounter(ctx context.Context, db *sql.DB, queries *tutorial.Queries, id int32) error {
tx, err := db.Begin()
if err != nil {
return err
}
defer tx.Rollback()
qtx := queries.WithTx(tx)
r, err := qtx.GetRecord(ctx, id)
if err != nil {
return err
}
if err := qtx.UpdateRecord(ctx, tutorial.UpdateRecordParams{
ID: r.ID,
Counter: r.Counter + 1,
}); err != nil {
return err
}
return tx.Commit()
}
// Using `github.com/jackc/pgx/v5` as the driver.
func bumpCounter(ctx context.Context, db *pgx.Conn, queries *tutorial.Queries, id int32) error {
tx, err := db.Begin(ctx)
if err != nil {
return err
}
defer tx.Rollback(ctx)
qtx := queries.WithTx(tx)
r, err := qtx.GetRecord(ctx, id)
if err != nil {
return err
}
if err := qtx.UpdateRecord(ctx, tutorial.UpdateRecordParams{
ID: r.ID,
Counter: r.Counter + 1,
}); err != nil {
return err
}
return tx.Commit(ctx)
}
```
================================================
FILE: docs/howto/update.md
================================================
# Updating rows
```sql
CREATE TABLE authors (
id SERIAL PRIMARY KEY,
bio text NOT NULL
);
```
## Single parameter
If your query has a single parameter, your Go method will also have a single
parameter.
The parameter syntax varies by database engine:
**PostgreSQL:**
```sql
-- name: UpdateAuthorBios :exec
UPDATE authors SET bio = $1;
```
**MySQL and SQLite:**
```sql
-- name: UpdateAuthorBios :exec
UPDATE authors SET bio = ?;
```
```go
package db
import (
"context"
"database/sql"
)
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const updateAuthorBios = `-- name: UpdateAuthorBios :exec
UPDATE authors SET bio = $1
`
func (q *Queries) UpdateAuthorBios(ctx context.Context, bio string) error {
_, err := q.db.ExecContext(ctx, updateAuthorBios, bio)
return err
}
```
## Multiple parameters
If your query has more than one parameter, your Go method will accept a
`Params` struct.
**PostgreSQL:**
```sql
-- name: UpdateAuthor :exec
UPDATE authors SET bio = $2
WHERE id = $1;
```
**MySQL and SQLite:**
```sql
-- name: UpdateAuthor :exec
UPDATE authors SET bio = ?
WHERE id = ?;
```
Note: For MySQL and SQLite, parameters are bound in the order they appear in the query, regardless of the order in the function signature.
```go
package db
import (
"context"
"database/sql"
)
type DBTX interface {
ExecContext(context.Context, string, ...interface{}) (sql.Result, error)
}
func New(db DBTX) *Queries {
return &Queries{db: db}
}
type Queries struct {
db DBTX
}
const updateAuthor = `-- name: UpdateAuthor :exec
UPDATE authors SET bio = $2
WHERE id = $1
`
type UpdateAuthorParams struct {
ID int32
Bio string
}
func (q *Queries) UpdateAuthor(ctx context.Context, arg UpdateAuthorParams) error {
_, err := q.db.ExecContext(ctx, updateAuthor, arg.ID, arg.Bio)
return err
}
```
================================================
FILE: docs/howto/verify.md
================================================
# `verify` - Verifying schema changes
*Added in v1.24.0*
Schema updates and poorly-written queries often bring down production databases. That’s bad.
Out of the box, `sqlc generate` catches some of these issues. Running `sqlc vet` with the `sqlc/db-prepare` rule catches more subtle problems. But there is a large class of issues that sqlc can’t prevent by looking at current schema and queries alone.
For instance, when a schema change is proposed, existing queries and code running in production might fail when the schema change is applied. Enter `sqlc verify`, which analyzes existing queries against new schema changes and errors if there are any issues.
Let's look at an example. Assume you have these two tables in production.
```sql
CREATE TABLE users (
id UUID PRIMARY KEY
);
CREATE TABLE user_actions (
id UUID PRIMARY KEY,
user_id UUID NOT NULL,
action TEXT,
created_at TIMESTAMP
);
```
Your application contains the following query to join user actions against the users table.
```sql
-- name: GetUserActions :many
SELECT * FROM users u
JOIN user_actions ua ON u.id = ua.user_id
ORDER BY created_at;
```
So far, so good. Then assume you propose this schema change:
```sql
ALTER TABLE users ADD COLUMN created_at TIMESTAMP;
```
Running `sqlc generate` fails with this change, returning a `column reference "created_at" is ambiguous` error. You update your query to fix the issue.
```sql
-- name: GetUserActions :many
SELECT * FROM users u
JOIN user_actions ua ON u.id = ua.user_id
ORDER BY u.created_at;
```
While that change fixes the issue, there's a production outage waiting to happen. When the schema change is applied, the existing `GetUserActions` query will begin to fail. The correct way to fix this is to deploy the updated query before applying the schema migration.
It ensures migrations are safe to deploy by sending your current schema and queries to sqlc cloud. There, we run the queries for your latest push against your new schema changes. This check catches backwards incompatible schema changes for existing queries.
Here `sqlc verify` alerts you to the fact that ORDER BY "created_at" is ambiguous.
```sh
$ sqlc verify
FAIL: app query.sql
=== Failed
=== FAIL: app query.sql GetUserActions
ERROR: column reference "created_at" is ambiguous (SQLSTATE 42702)
```
By the way, this scenario isn't made up! It happened to us a few weeks ago. We've been happily testing early versions of `verify` for the last two weeks and haven't had any issues since.
This type of verification is only the start. If your application is deployed on-prem by your customers, `verify` could tell you if it's safe for your customers to rollback to an older version of your app, even after schema migrations have been run.
Using `verify` requires that you push your queries and schema when you tag a release of your application. We run it on every push to main, as we continuously deploy those commits.
## Authentication
`sqlc` expects to find a valid auth token in the value of the `SQLC_AUTH_TOKEN`
environment variable. You can create an auth token via the [dashboard](https://dashboard.sqlc.dev).
```shell
export SQLC_AUTH_TOKEN=sqlc_xxxxxxxx
```
## Expected workflow
Using `sqlc verify` requires pushing your queries and schema to sqlc Cloud. When
you release a new version of your application, you should push your schema and
queries as well. For example, we run `sqlc push` after any change has been
merged into our `main` branch on Github, as we deploy every commit to
production.
```shell
$ sqlc push --tag main
```
Locally or in pull requests, run `sqlc verify` to check that existing queries
continue to work with your current database schema.
```shell
$ sqlc verify --against main
```
## Picking a tag
Without an `against` argument, `verify` will run its analysis of the provided schema using your most-recently pushed queries. We suggest using the `against` argument to explicitly select a set of queries for comparison.
```shell
$ sqlc verify --against [tag]
```
================================================
FILE: docs/howto/vet.md
================================================
# `vet` - Linting queries
*Added in v1.19.0*
`sqlc vet` runs queries through a set of lint rules.
Rules are defined in the `sqlc` [configuration](../reference/config) file. They
consist of a name, message, and a [Common Expression Language
(CEL)](https://github.com/google/cel-spec) expression. Expressions are evaluated
using [cel-go](https://github.com/google/cel-go). If an expression evaluates to
`true`, `sqlc vet` will report an error using the given message.
## Defining lint rules
Each lint rule's CEL expression has access to information from your sqlc
configuration and queries via variables defined in the following proto messages.
```proto
message Config
{
string version = 1;
string engine = 2 ;
repeated string schema = 3;
repeated string queries = 4;
}
message Query
{
// SQL body
string sql = 1;
// Name of the query
string name = 2;
// One of "many", "one", "exec", etc.
string cmd = 3;
// Query parameters, if any
repeated Parameter params = 4;
}
message Parameter
{
int32 number = 1;
}
```
In addition to this basic information, when you have a PostgreSQL or MySQL
[database connection configured](../reference/config.md#database)
each CEL expression has access to the output from running `EXPLAIN ...` on your query
via the `postgresql.explain` and `mysql.explain` variables.
This output is quite complex and depends on the structure of your query but sqlc attempts
to parse and provide as much information as it can. See
[Rules using `EXPLAIN ...` output](#rules-using-explain-output) for more information.
Here are a few example rules just using the basic configuration and query information available
to the CEL expression environment. While these examples are simplistic, they give you a flavor
of the types of rules you can write.
```yaml
version: 2
sql:
- schema: "query.sql"
queries: "query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
rules:
- no-pg
- no-delete
- only-one-param
- no-exec
rules:
- name: no-pg
message: "invalid engine: postgresql"
rule: |
config.engine == "postgresql"
- name: no-delete
message: "don't use delete statements"
rule: |
query.sql.contains("DELETE")
- name: only-one-param
message: "too many parameters"
rule: |
query.params.size() > 1
- name: no-exec
message: "don't use exec"
rule: |
query.cmd == "exec"
```
### Rules using `EXPLAIN ...` output
*Added in v1.20.0*
The CEL expression environment has two variables containing `EXPLAIN ...` output,
`postgresql.explain` and `mysql.explain`. `sqlc` only populates the variable associated with
your configured database engine, and only when you have a
[database connection configured](../reference/config.md#database).
For the `postgresql` engine, `sqlc` runs
```sql
EXPLAIN (ANALYZE false, VERBOSE, COSTS, SETTINGS, BUFFERS, FORMAT JSON) ...
```
where `"..."` is your query string, and parses the output into a [`PostgreSQLExplain`](https://buf.build/sqlc/sqlc/docs/v1.20.0:vet#vet.PostgreSQLExplain) proto message.
For the `mysql` engine, `sqlc` runs
```sql
EXPLAIN FORMAT=JSON ...
```
where `"..."` is your query string, and parses the output into a [`MySQLExplain`](https://buf.build/sqlc/sqlc/docs/v1.20.0:vet#vet.MySQLExplain) proto message.
These proto message definitions are too long to include here, but you can find them in the `protos`
directory within the `sqlc` source tree.
The output from `EXPLAIN ...` depends on the structure of your query so it's a bit difficult
to offer generic examples. Refer to the
[PostgreSQL documentation](https://www.postgresql.org/docs/current/using-explain.html) and
[MySQL documentation](https://dev.mysql.com/doc/refman/en/explain-output.html) for more
information.
```yaml
...
rules:
- name: postgresql-query-too-costly
message: "Query cost estimate is too high"
rule: "postgresql.explain.plan.total_cost > 1.0"
- name: postgresql-no-seq-scan
message: "Query plan results in a sequential scan"
rule: "postgresql.explain.plan.node_type == 'Seq Scan'"
- name: mysql-query-too-costly
message: "Query cost estimate is too high"
rule: "has(mysql.explain.query_block.cost_info) && double(mysql.explain.query_block.cost_info.query_cost) > 2.0"
- name: mysql-must-use-primary-key
message: "Query plan doesn't use primary key"
rule: "has(mysql.explain.query_block.table.key) && mysql.explain.query_block.table.key != 'PRIMARY'"
```
When building rules that depend on `EXPLAIN ...` output, it may be helpful to see the actual JSON
returned from the database. `sqlc` will print it When you set the environment variable
`SQLCDEBUG=dumpexplain=1`. Use this environment variable together with a dummy rule to see
`EXPLAIN ...` output for all of your queries.
```yaml
version: 2
sql:
- schema: "query.sql"
queries: "query.sql"
engine: "postgresql"
database:
uri: "postgresql://postgres:postgres@localhost:5432/postgres"
gen:
go:
package: "db"
out: "db"
rules:
- debug
rules:
- name: debug
rule: "!has(postgresql.explain)" # A dummy rule to trigger explain
```
Please note that databases configured with a `uri` must have an up-to-date
schema for `vet` to work correctly, and `sqlc` does not apply schema migrations
to your database. Use your migration tool of choice to create the necessary
tables and objects before running `sqlc vet` with rules that depend on
`EXPLAIN ...` output.
Alternatively, configure [managed databases](managed-databases.md) to have
`sqlc` create hosted ephemeral databases with the correct schema automatically.
## Built-in rules
### sqlc/db-prepare
When a [database](../reference/config.md#database) connection is configured, you can
run the built-in `sqlc/db-prepare` rule. This rule will attempt to prepare
each of your queries against the connected database and report any failures.
```yaml
version: 2
sql:
- schema: "schema.sql"
queries: "query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
database:
uri: "postgresql://postgres:password@localhost:5432/postgres"
rules:
- sqlc/db-prepare
```
Please note that databases configured with a `uri` must have an up-to-date
schema for `vet` to work correctly, and `sqlc` does not apply schema migrations
to your database. Use your migration tool of choice to create the necessary
tables and objects before running `sqlc vet` with the `sqlc/db-prepare` rule.
Alternatively, configure [managed databases](managed-databases.md) to have
`sqlc` create hosted ephemeral databases with the correct schema automatically.
```yaml
version: 2
cloud:
project: "<PROJECT_ID>"
sql:
- schema: "schema.sql"
queries: "query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
database:
managed: true
rules:
- sqlc/db-prepare
```
To see this in action, check out the [authors
example](https://github.com/sqlc-dev/sqlc/blob/main/examples/authors/sqlc.yaml).
## Running lint rules
When you add the name of a defined rule to the rules list
for a [sql package](../reference/config.md#sql),
`sqlc vet` will evaluate that rule against every query in the package.
In the example below, two rules are defined but only one is enabled.
```yaml
version: 2
sql:
- schema: "query.sql"
queries: "query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
rules:
- no-delete
rules:
- name: no-pg
message: "invalid engine: postgresql"
rule: |
config.engine == "postgresql"
- name: no-delete
message: "don't use delete statements"
rule: |
query.sql.contains("DELETE")
```
### Opting-out of lint rules
For any query, you can tell `sqlc vet` not to evaluate lint rules using the
`@sqlc-vet-disable` query annotation. The annotation accepts a list of rules to ignore.
```sql
/* name: GetAuthor :one */
/* @sqlc-vet-disable sqlc/db-prepare no-pg */
SELECT * FROM authors
WHERE id = ? LIMIT 1;
```
The rules can also be split across lines.
```sql
/* name: GetAuthor :one */
/* @sqlc-vet-disable sqlc/db-prepare */
/* @sqlc-vet-disable no-pg */
SELECT * FROM authors
WHERE id = ? LIMIT 1;
```
To skip all rules for a query, you can provide the `@sqlc-vet-disable` annotation without any parameters.
```sql
/* name: GetAuthor :one */
/* @sqlc-vet-disable */
SELECT * FROM authors
WHERE id = ? LIMIT 1;
```
================================================
FILE: docs/index.rst
================================================
.. sqlc documentation master file, created by
sphinx-quickstart on Mon Feb 1 23:18:36 2021.
You can adapt this file completely to your liking, but it should at least
contain the root `toctree` directive.
sqlc Documentation
==================
And lo, the Great One looked down upon the people and proclaimed:
"SQL is actually pretty great"
sqlc generates **fully type-safe idiomatic Go code** from SQL. Here's how it
works:
1. You write SQL queries
2. You run sqlc to generate Go code that presents type-safe interfaces to those
queries
3. You write application code that calls the methods sqlc generated
Seriously, it's that easy. You don't have to write any boilerplate SQL querying
code ever again.
.. toctree::
:maxdepth: 2
:caption: Overview
:hidden:
overview/install.md
.. toctree::
:maxdepth: 2
:caption: Tutorials
:hidden:
tutorials/getting-started-mysql.md
tutorials/getting-started-postgresql.md
tutorials/getting-started-sqlite.md
.. toctree::
:maxdepth: 2
:caption: Commands
:hidden:
howto/generate.md
howto/push.md
howto/verify.md
howto/vet.md
.. toctree::
:maxdepth: 2
:caption: How-to Guides
:hidden:
howto/select.md
howto/query_count.md
howto/insert.md
howto/update.md
howto/delete.md
howto/prepared_query.md
howto/transactions.md
howto/named_parameters.md
howto/ddl.md
howto/structs.md
howto/embedding.md
howto/overrides.md
howto/rename.md
.. toctree::
:maxdepth: 3
:caption: sqlc Cloud
:hidden:
howto/managed-databases.md
.. toctree::
:maxdepth: 3
:caption: Reference
:hidden:
reference/changelog.md
reference/cli.md
reference/config.md
reference/datatypes.md
reference/environment-variables.md
reference/language-support.rst
reference/macros.md
reference/query-annotations.md
.. toctree::
:maxdepth: 2
:caption: Conceptual Guides
:hidden:
howto/ci-cd.md
guides/using-go-and-pgx.rst
guides/plugins.md
guides/development.md
guides/privacy.md
================================================
FILE: docs/overview/install.md
================================================
# Installing sqlc
sqlc is distributed as a single binary with zero dependencies.
## macOS
```
brew install sqlc
```
## Ubuntu
```
sudo snap install sqlc
```
## go install
Installing recent versions of sqlc requires Go 1.21+.
```
go install github.com/sqlc-dev/sqlc/cmd/sqlc@latest
```
## Docker
```
docker pull sqlc/sqlc
```
Run `sqlc` using `docker run`:
```
docker run --rm -v $(pwd):/src -w /src sqlc/sqlc generate
```
Run `sqlc` using `docker run` in the Command Prompt on Windows (`cmd`):
```
docker run --rm -v "%cd%:/src" -w /src sqlc/sqlc generate
```
## Downloads
Get pre-built binaries for *v1.30.0*:
- [Linux](https://downloads.sqlc.dev/sqlc_1.30.0_linux_amd64.tar.gz)
- [macOS](https://downloads.sqlc.dev/sqlc_1.30.0_darwin_amd64.zip)
- [Windows](https://downloads.sqlc.dev/sqlc_1.30.0_windows_amd64.zip)
See [downloads.sqlc.dev](https://downloads.sqlc.dev/) for older versions.
================================================
FILE: docs/reference/changelog.md
================================================
# Changelog
All notable changes to this project will be documented in this file.
(v1-30-0)=
## [1.30.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.30.0)
Released 2025-09-01
### Bug Fixes
- (compiler/mysql) Prevent panic in convertSetOprSelectList() (#4042)
- Range subselect alias pointer dereference (#3711)
- (codegen/golang) Don't omit enums used as arrays (#4058)
- (codegen/golang) Handle `go_struct_tag` for `db_type` overrides (#4055)
- (engine/dolphin) Remove references to deprecated `pcast.ChangeStmt` (#4057)
- Normalize identifier usage for table names (#4045)
- (engine/sqlite) Fix parsing of INSERT DEFAULT VALUES syntax (#4010)
### Documentation
- Fix parameter syntax inconsistency for MySQL and SQLite (#4036)
- Use correct configuration to generate the given output for JSON type override (#4049)
- Clean up and add to docs regarding type overrides (#4060)
- Try a different admonition format (#4061)
- Use the correct admonition format (#4062)
- Add multi-worded table example for renaming (#4067)
### Features
- (docs) Add link to Gleam/parrot (#4038)
- (engine/dolphin) Implement MATCH_AGAINST conversion in SQL AST (#1192, #3091) (#4070)
- (engine/sqlite) Coerce jsonb columns to json before returning to Go code (#3968)
### Testing
- (endtoend) Skip process_plugin_sqlc_gen_json (#4075)
- (endtoend) Use Docker to start database servers (#4076)
### Build
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3941)
- (deps) Bump packaging (#3940)
- (deps) Bump golang from 1.24.2 to 1.24.4 (#3983)
- (deps) Bump golang from 1.24.4 to 1.24.5 (#4014)
- (deps) Bump urllib3 from 2.4.0 to 2.5.0 in /docs (#3994)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3989)
- (deps) Bump the production-dependencies group across 1 directory with 4 updates (#4027)
- (deps) Bump modernc.org/sqlite (#4032)
- (deps) Bump the production-dependencies group across 1 directory with 4 updates (#4018)
- (deps) Bump certifi in /docs in the production-dependencies group (#4041)
- (deps) Bump google.golang.org/protobuf (#4043)
- (deps) Bump actions/checkout from 4 to 5 (#4059)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#4071)
- (deps) Bump requests in /docs in the production-dependencies group (#4068)
- Upgrade to Go 1.25 (#4074)
- (deps) Bump golang from 1.24.5 to 1.25.0 (#4063)
- (deps) Bump github.com/google/cel-go (#4080)
(v1-29-0)=
## [1.29.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.29.0)
Released 2025-04-14
### Bug Fixes
- (docs) Correct spelling and grammar (#3645)
- (dbmanager) Use correct SQL to drop databases (#3640)
- (compiler) Don't crash on WHERE x IN (... UNION ...) (#3652)
- (golang) Escape q field name (#3647)
- Postgresql alter materialized view is not registered to statements (#3728)
- Do not close wazero module on error (#3758) (#3759)
- (pgx) Do not wrap nil error (#3913)
- (migrations) Normalize case for migration statement for all cases (#3919)
### Documentation
- Add missing documentation about copyfrom (#3583)
- Add sqlc-gen-from-template (#3601)
- Add changelog for 1.28.0 (#3797)
- Add PHP DBAL plugin (#3813)
- Fix PostGIS function name (#3829)
- Add Zig plugin (#3824)
- Add link to tandemdude/sqlc-gen-java (#3819)
### Features
- (docs) How-to use transactions with pgx (#3557)
- (quickdb) Remove unused func (#3576)
- (vet) Allow selective disabling of rules per query (#3620)
- (dolphin) Upgrade to latest TiDB parser (#3733)
- (mysql) Add a test for VECTOR column type (#3734)
- (cli) Bump version from 1.27.0 to 1.28.0 (#3798)
- (codegen/golang) Add an option to wrap query errors that includes query name (#3876)
### Miscellaneous Tasks
- Remove the triage label (#3527)
- Upgrade to Go 1.22.8 to silence vulncheck (#3646)
- Update sqlc-gen-java supported engines (#3843)
### Build
- (deps) Bump myst-parser (#3530)
- (deps) Bump golang from 1.22.5 to 1.22.6 (#3532)
- (deps) Bump modernc.org/sqlite (#3537)
- (deps) Bump the production-dependencies group across 1 directory with 4 updates (#3566)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3565)
- (deps) Bump golang from 1.22.6 to 1.23.0 (#3546)
- (deps) Bump golang from 1.23.0 to 1.23.1 (#3586)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3644)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3642)
- (deps) Bump sphinx-rtd-theme (#3648)
- (deps) Bump pyparsing (#3653)
- (deps) Bump markupsafe (#3666)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3707)
- (deps) Bump golang from 1.23.2 to 1.23.3 (#3691)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3721)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3731)
- (deps) Bump certifi in /docs in the production-dependencies group (#3748)
- (deps) Bump golang.org/x/crypto from 0.27.0 to 0.31.0 (#3740)
- (deps) Bump golang from 1.23.3 to 1.23.4 (#3735)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3749)
- (deps) Bump the production-dependencies group with 2 updates (#3753)
- (deps) Bump the production-dependencies group across 1 directory with 3 updates (#3764)
- (deps) Bump the production-dependencies group (#3761)
- (deps) Bump jinja2 from 3.1.4 to 3.1.5 in /docs (#3762)
- (deps) Bump google.golang.org/protobuf (#3776)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3777)
- (deps) Bump google.golang.org/grpc (#3784)
- (deps) Bump golang from 1.23.4 to 1.23.5 (#3791)
- (deps) Bump the production-dependencies group with 2 updates (#3789)
- Upgrade to Go 1.23.5 (#3795)
- (deps) Bump golang.org/x/net from 0.30.0 to 0.33.0 (#3796)
- (deps) Bump golang from 1.23.5 to 1.23.6 (#3822)
- Use govulncheck action (#3831)
- (deps) Bump the production-dependencies group across 1 directory with 3 updates (#3817)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3826)
- (deps) Bump golang from 1.23.6 to 1.24.0 (#3842)
- (deps) Bump myst-parser (#3841)
- (deps) Bump modernc.org/sqlite (#3846)
- (deps) Bump golang from 1.24.0 to 1.24.1 (#3870)
- (deps) Bump jinja2 in /docs in the production-dependencies group (#3872)
- Upgrade to wazero@v1.9.0 (#3887)
- Upgrade to Go 1.24.1 (#3892)
- Upgrade to latest version of MySQL parser (#3893)
- (deps) Bump pyparsing (#3890)
- (deps) Bump golang.org/x/net from 0.33.0 to 0.37.0 (#3894)
- (deps) Bump the production-dependencies group across 1 directory with 8 updates (#3896)
- (deps) Bump github.com/jackc/pgx/v5 (#3898)
- (deps) Bump the production-dependencies group (#3899)
- (deps) Bump modernc.org/sqlite (#3905)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3914)
- (deps) Bump urllib3 in /docs in the production-dependencies group (#3926)
- (deps) Bump golang from 1.24.1 to 1.24.2 (#3915)
- (deps) Bump the production-dependencies group across 1 directory with 3 updates (#3923)
- (deps) Upgrade github.com/wasilibs/go-pgquery (#3927)
(v1-28-0)=
## [1.28.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.28.0)
Released 2025-01-20
### Features
- (mysql) Add a test for VECTOR column type (#3734)
- (quickdb) Remove unused func (#3576)
- (vet) Allow selective disabling of rules per query (#3620)
- (dolphin) Upgrade to latest TiDB parser (#3733)
### Bug Fixes
- (dbmanager) Use correct SQL to drop databases (#3640)
- (compiler) Don't crash on WHERE x IN (... UNION ...) (#3652)
- (golang) Escape q field name (#3647)
- Postgresql alter materialized view is not registered to statements (#3728)
- Do not close wazero module on error (#3758) (#3759)
### Documentation
- How-to use transactions with pgx (#3557)
- Add missing documentation about copyfrom (#3583)
- Add sqlc-gen-from-template (#3601)
- Correct spelling and grammar (#3645)
### Miscellaneous Tasks
- Remove the triage label (#3527)
- Upgrade to Go 1.22.8 to silence vulncheck (#3646)
### Build
- (deps) Bump myst-parser (#3530)
- (deps) Bump golang from 1.22.5 to 1.22.6 (#3532)
- (deps) Bump modernc.org/sqlite (#3537)
- (deps) Bump the production-dependencies group across 1 directory with 4 updates (#3566)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3565)
- (deps) Bump golang from 1.22.6 to 1.23.0 (#3546)
- (deps) Bump golang from 1.23.0 to 1.23.1 (#3586)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3644)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3642)
- (deps) Bump sphinx-rtd-theme (#3648)
- (deps) Bump pyparsing (#3653)
- (deps) Bump markupsafe (#3666)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3707)
- (deps) Bump golang from 1.23.2 to 1.23.3 (#3691)
- (deps) Bump the production-dependencies group across 1 directory with 5 updates (#3721)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3731)
- (deps) Bump certifi in /docs in the production-dependencies group (#3748)
- (deps) Bump golang.org/x/crypto from 0.27.0 to 0.31.0 (#3740)
- (deps) Bump golang from 1.23.3 to 1.23.4 (#3735)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3749)
- (deps) Bump the production-dependencies group with 2 updates (#3753)
- (deps) Bump the production-dependencies group across 1 directory with 3 updates (#3764)
- (deps) Bump the production-dependencies group (#3761)
- (deps) Bump jinja2 from 3.1.4 to 3.1.5 in /docs (#3762)
- (deps) Bump google.golang.org/protobuf (#3776)
- (deps) Bump the production-dependencies group across 1 directory with 2 updates (#3777)
- (deps) Bump google.golang.org/grpc (#3784)
- (deps) Bump golang from 1.23.4 to 1.23.5 (#3791)
- (deps) Bump the production-dependencies group with 2 updates (#3789)
- Upgrade to Go 1.23.5 (#3795)
(v1-27-0)=
## [1.27.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.27.0)
Released 2024-08-05
### Bug Fixes
- (dbmanager) Add leading slash to db uri path rewrite (#3493)
- (verify) Include database engine in request (#3522)
### Features
- (golang) Add initialisms configuration (#3308)
- (compiler) Support subqueries in the FROM clause (second coming) (#3310)
- Managed databases with any accessible server (#3421)
- (vet) Use new dbmanager client (#3423)
- (verify) Update verify to work with managed databases (#3425)
### Documentation
- Fix typo in config (#3358)
- Resolve a typo in configuration keys (#3349)
- Add sponsorship information to README (#3413)
- Update the language-support to include C# (#3408)
- Add migration guide for hosted managed databases (#3417)
- Fix readme links (#3424)
- Update the managed db and verify documentation (#3426)
- Add sponsor image (#3428)
- Add Ruby as supported language (#3487)
- Update migrating-to-sqlc-gen-kotlin.md (#3454)
- Fix typo in comment (#3316)
- Fix deprecated build tag format (#3361)
### Testing
- (endtoend) Re-use databases when possible (#3315)
- Enabled MySQL database (#3318)
- Remove internal/sqltest/hosted package (#3521)
(v1-26-0)=
## [1.26.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.26.0)
Released 2024-03-28
### Release notes
This release is mainly a bug fix release. It also includes an [important security fix](https://github.com/sqlc-dev/sqlc/issues/3194) for users using output plugins.
### Changes
#### Bug Fixes
- (docker) Use distroless base image instead of scratch (#3111)
- (generate) Ensure files are created inside output directory (#3195)
- (mysql) BREAKING: Use `int16` for MySQL `SMALLINT` and `YEAR` (#3106)
- (mysql) BREAKING: Use `int8` for MySQL TINYINT (#3298)
- (mysql) Variables not resolving in ORDER BY statements (#3115)
- (opts) Validate SQL package and driver options (#3241)
- (postgres/batch) Ignore query_parameter_limit for batches
- (scripts) Remove deprecated test output regeneration script (#3105)
- (sqlite) Correctly skip unknown statements (#3239)
#### Documentation
- (postgres) Add instructions for PostGIS/GEOS (#3182)
- Improve details on TEXT (#3247)
#### Features
- (generate) Avoid generating empty Go imports (#3135)
- (mysql) Add NEXTVAL() to the MySQL catalog (#3147)
- (mysql) Support json.RawMessage for LOAD DATA INFILE (#3099)
#### Build
- (deps) Bump github.com/jackc/pgx/v5 to 5.5.5 (#3259)
- (deps) Bump modernc.org/sqlite to 1.29.5 (#3200)
- (deps) Bump github.com/go-sql-driver/mysql to 1.8.0 (#3257)
- (deps) Bump github.com/tetratelabs/wazero to 1.7.0 (#3096)
- (deps) Bump github.com/pganalyze/pg_query_go to v5 (#3096)
(v1-25-0)=
## [1.25.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.25.0)
Released 2024-01-03
### Release notes
#### Add tags to push and verify
You can add tags when [pushing](../howto/push.md) schema and queries to [sqlc Cloud](https://dashboard.sqlc.dev). Tags operate like git tags, meaning you can overwrite previously-pushed tag values. We suggest tagging pushes to associate them with something relevant from your environment, e.g. a git tag or branch name.
```
$ sqlc push --tag v1.0.0
```
Once you've created a tag, you can refer to it when [verifying](../howto/verify.md) changes, allowing you
to compare the existing schema against a known set of previous queries.
```
$ sqlc verify --against v1.0.0
```
#### C-ya, `cgo`
Over the last month, we've switched out a few different modules to remove our reliance on [cgo](https://go.dev/blog/cgo). Previously, we needed cgo for three separate functions:
- Parsing PostgreSQL queries with [pganalyze/pg_query_go](https://github.com/pganalyze/pg_query_go)
- Running SQLite databases with [mattn/go-sqlite3](https://github.com/mattn/go-sqlite3)
- Executing WASM / WASI code with [bytecodealliance/wasmtime-go](https://github.com/bytecodealliance/wasmtime-go)
With the help of the community, we found cgo-free alternatives for each module:
- Parsing PostgreSQL queries, now using [wasilibs/go-pgquery](https://github.com/wasilibs/go-pgquery)
- Running SQLite databases, now using [modernc.org/sqlite](https://gitlab.com/cznic/sqlite)
- Executing WASM / WASI code, now using [tetratelabs/wazero](https://github.com/tetratelabs/wazero)
For the first time, Windows users can enjoy full PostgreSQL support without using [WSL](https://learn.microsoft.com/en-us/windows/wsl/about). It's a Christmas miracle!
If you run into any issues with the updated dependencies, please [open an issue](https://github.com/sqlc-dev/sqlc/issues).
### Changes
#### Bug Fixes
- (codegen) Wrong yaml annotation in go codegen options for output_querier_file_name (#3006)
- (codegen) Use derived ArrayDims instead of deprecated attndims (#3032)
- (codegen) Take the maximum array dimensions (#3034)
- (compiler) Skip analysis of queries without a `name` annotation (#3072)
- (codegen/golang) Don't import `"strings"` for `sqlc.slice()` with pgx (#3073)
### Documentation
- Add name to query set configuration (#3011)
- Add a sidebar link for `push`, add Go plugin link (#3023)
- Update banner for sqlc-gen-typescript (#3036)
- Add strict_order_by in doc (#3044)
- Re-order the migration tools list (#3064)
### Features
- (analyzer) Return zero values when encountering unexpected ast nodes (#3069)
- (codegen/go) add omit_sqlc_version to Go code generation (#3019)
- (codgen/go) Add `emit_sql_as_comment` option to Go code plugin (#2735)
- (plugins) Use wazero instead of wasmtime (#3042)
- (push) Add tag support (#3074)
- (sqlite) Support emit_pointers_for_null_types (#3026)
### Testing
- (endtoend) Enable for more build targets (#3041)
- (endtoend) Run MySQL and PostgreSQL locally on the runner (#3095)
- (typescript) Test against sqlc-gen-typescript (#3046)
- Add tests for omit_sqlc_version (#3020)
- Split schema and query for test (#3094)
### Build
- (deps) Bump idna from 3.4 to 3.6 in /docs (#3010)
- (deps) Bump sphinx-rtd-theme from 1.3.0 to 2.0.0 in /docs (#3016)
- (deps) Bump golang from 1.21.4 to 1.21.5 (#3043)
- (deps) Bump actions/setup-go from 4 to 5 (#3047)
- (deps) Bump github.com/jackc/pgx/v5 from 5.5.0 to 5.5.1 (#3050)
- (deps) Upgrade to latest version of github.com/wasilibs/go-pgquery (#3052)
- (deps) Bump google.golang.org/grpc from 1.59.0 to 1.60.0 (#3053)
- (deps) Bump babel from 2.13.1 to 2.14.0 in /docs (#3055)
- (deps) Bump actions/upload-artifact from 3 to 4 (#3061)
- (deps) Bump modernc.org/sqlite from 1.27.0 to 1.28.0 (#3062)
- (deps) Bump golang.org/x/crypto from 0.14.0 to 0.17.0 (#3068)
- (deps) Bump google.golang.org/grpc from 1.60.0 to 1.60.1 (#3070)
- (deps) Bump google.golang.org/protobuf from 1.31.0 to 1.32.0 (#3079)
- (deps) Bump github.com/tetratelabs/wazero from 1.5.0 to 1.6.0 (#3096)
- (sqlite) Update to antlr 4.13.1 (#3086)
- (sqlite) Disable modernc for WASM (#3048)
- (sqlite) Switch from mattn/go-sqlite3 to modernc.org/sqlite (#3040)
(v1-24-0)=
## [1.24.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.24.0)
Released 2023-11-22
### Release notes
#### Verifying database schema changes
Schema updates and poorly-written queries often bring down production databases. That’s bad.
Out of the box, `sqlc generate` catches some of these issues. Running `sqlc vet` with the `sqlc/db-prepare` rule catches more subtle problems. But there is a large class of issues that sqlc can’t prevent by looking at current schema and queries alone.
For instance, when a schema change is proposed, existing queries and code running in production might fail when the schema change is applied. Enter `sqlc verify`, which analyzes existing queries against new schema changes and errors if there are any issues.
Let's look at an example. Assume you have these two tables in production.
```sql
CREATE TABLE users (
id UUID PRIMARY KEY
);
CREATE TABLE user_actions (
id UUID PRIMARY KEY,
user_id UUID NOT NULL,
action TEXT,
created_at TIMESTAMP
);
```
Your application contains the following query to join user actions against the users table.
```sql
-- name: GetUserActions :many
SELECT * FROM users u
JOIN user_actions ua ON u.id = ua.user_id
ORDER BY created_at;
```
So far, so good. Then assume you propose this schema change:
```sql
ALTER TABLE users ADD COLUMN created_at TIMESTAMP;
```
Running `sqlc generate` fails with this change, returning a `column reference "created_at" is ambiguous` error. You update your query to fix the issue.
```sql
-- name: GetUserActions :many
SELECT * FROM users u
JOIN user_actions ua ON u.id = ua.user_id
ORDER BY u.created_at;
```
While that change fixes the issue, there's a production outage waiting to happen. When the schema change is applied, the existing `GetUserActions` query will begin to fail. The correct way to fix this is to deploy the updated query before applying the schema migration.
It ensures migrations are safe to deploy by sending your current schema and queries to sqlc cloud. There, we run the queries for your latest push against your new schema changes. This check catches backwards incompatible schema changes for existing queries.
Here `sqlc verify` alerts you to the fact that ORDER BY "created_at" is ambiguous.
```sh
$ sqlc verify
FAIL: app query.sql
=== Failed
=== FAIL: app query.sql GetUserActions
ERROR: column reference "created_at" is ambiguous (SQLSTATE 42702)
```
By the way, this scenario isn't made up! It happened to us a few weeks ago. We've been happily testing early versions of `verify` for the last two weeks and haven't had any issues since.
This type of verification is only the start. If your application is deployed on-prem by your customers, `verify` could tell you if it's safe for your customers to rollback to an older version of your app, even after schema migrations have been run.
#### Rename `upload` command to `push`
We've renamed the `upload` sub-command to `push`. We changed the data sent along in a push request. Upload used to include the configuration file, migrations, queries, and all generated code. Push drops the generated code in favor of including the [plugin.GenerateRequest](https://buf.build/sqlc/sqlc/docs/main:plugin#plugin.GenerateRequest), which is the protocol buffer message we pass to codegen plugins.
We also add annotations to each push. By default, we include these environment variables if they are present:
```
GITHUB_REPOSITORY
GITHUB_REF
GITHUB_REF_NAME
GITHUB_REF_TYPE
GITHUB_SHA
```
Like upload, `push` should be run when you tag a release of your application. We run it on every push to main, as we continuously deploy those commits.
#### MySQL support in `createdb`
The `createdb` command, added in the last release, now supports MySQL. If you have a cloud project configured, you can use `sqlc createdb` to spin up a new ephemeral database with your schema and print its connection string to standard output. This is useful for integrating with other tools. Read more in the [managed databases](../howto/managed-databases.md#with-other-tools) documentation.
#### Plugin interface refactor
This release includes a refactored plugin interface to better support future functionality. Plugins now support different methods via a gRPC service interface, allowing plugins to support different functionality in a backwards-compatible way.
By using gRPC interfaces, we can even (theoretically) support [remote plugins](https://github.com/sqlc-dev/sqlc/pull/2938), but that's something for another day.
### Changes
#### Bug Fixes
- (engine/sqlite) Support CASE expr (#2926)
- (engine/sqlite) Support -> and ->> operators (#2927)
- (vet) Add a nil pointer check to prevent db/prepare panic (#2934)
- (compiler) Prevent panic when compiler is nil (#2942)
- (codegen/golang) Move more Go-specific config validation into the plugin (#2951)
- (compiler) No panic on full-qualified column names (#2956)
- (docs) Better discussion of type override nuances (#2972)
- (codegen) Never generate return structs for :exec (#2976)
- (generate) Update help text for generate to be more generic (#2981)
- (generate) Return an error instead of generating duplicate Go names (#2962)
- (codegen/golang) Pull opts into its own package (#2920)
- (config) Make some struct and field names less confusing (#2922)
#### Features
- (codegen) Remove Go specific overrides from codegen proto (#2929)
- (plugin) Use gRPC interface for codegen plugin communication (#2930)
- (plugin) Calculate SHA256 if it does not exist (#2935)
- (sqlc-gen-go) Add script to mirror code to sqlc-gen-go (#2952)
- (createdb) Add support for MySQL (#2980)
- (verify) Add new command to verify queries and migrations (#2986)
#### Testing
- (ci) New workflow for sqlc-gen-python (#2936)
- (ci) Rely on go.mod to determine which Go version to use (#2971)
- (tests) Add glob pattern tests to sqlpath.Glob (#2995)
- (examples) Use hosted MySQL databases for tests (#2982)
- (docs) Clean up a little, update LICENSE and README (#2941)
#### Build
- (deps) Bump babel from 2.13.0 to 2.13.1 in /docs (#2911)
- (deps) Bump github.com/spf13/cobra from 1.7.0 to 1.8.0 (#2944)
- (deps) Bump github.com/mattn/go-sqlite3 from 1.14.17 to 1.14.18 (#2945)
- (deps) Bump golang.org/x/sync from 0.4.0 to 0.5.0 (#2946)
- (deps) Bump github.com/jackc/pgx/v5 from 5.4.3 to 5.5.0 (#2947)
- (deps) Change github.com/pingcap/tidb/parser to github.com/pingcap/tidb/pkg/parser
- (deps) Bump github.com/google/cel-go from 0.18.1 to 0.18.2 (#2969)
- (deps) Bump urllib3 from 2.0.7 to 2.1.0 in /docs (#2975)
- (buf) Change root of Buf module (#2987)
- (deps) Bump certifi from 2023.7.22 to 2023.11.17 in /docs (#2993)
- (ci) Bump Go version from 1.21.3 to 1.21.4 in workflows and Dockerfile (#2961)
(v1-23-0)=
## [1.23.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.23.0)
Released 2023-10-24
### Release notes
#### Database-backed query analysis
With a [database connection](config.md#database) configured, `sqlc generate`
will gather metadata from that database to support its query analysis.
Turning this on resolves a [large number of
issues](https://github.com/sqlc-dev/sqlc/issues?q=is%3Aissue+label%3Aanalyzer)
in the backlog related to type inference and more complex queries. The easiest
way to try it out is with [managed databases](../howto/managed-databases.md).
The database-backed analyzer currently supports PostgreSQL, with [MySQL](https://github.com/sqlc-dev/sqlc/issues/2902) and [SQLite](https://github.com/sqlc-dev/sqlc/issues/2903)
support planned in the future.
#### New `createdb` command
When you have a cloud project configured, you can use the new `sqlc createdb`
command to spin up a new ephemeral database with your schema and print its
connection string to standard output. This is useful for integrating with other
tools. Read more in the [managed
databases](../howto/managed-databases.md#with-other-tools) documentation.
#### Support for pgvector
If you're using [pgvector](https://github.com/pgvector/pgvector), say goodbye to custom overrides! sqlc now generates code using [pgvector-go](https://github.com/pgvector/pgvector-go#pgx) as long as you're using `pgx`. The pgvector extension is also available in [managed databases](../howto/managed-databases.md).
#### Go build tags
With the new `emit_build_tags` configuration parameter you can set build tags
for sqlc to add at the top of generated source files.
### Changes
#### Bug Fixes
- (codegen) Correct column names in :copyfrom (#2838)
- (compiler) Search SELECT and UPDATE the same way (#2841)
- (dolphin) Support more UNIONs for MySQL (#2843)
- (compiler) Account for parameters without parents (#2844)
- (postgresql) Remove temporary pool config (#2851)
- (golang) Escape reserved keywords (#2849)
- (mysql) Handle simplified CASE statements (#2852)
- (engine/dolphin) Support enum in ALTER definition (#2680)
- (mysql) Add, drop, rename and change enum values (#2853)
- (config) Validate `database` config in all cases (#2856)
- (compiler) Use correct func signature for `CommentSyntax` on windows (#2867)
- (codegen/go) Prevent filtering of embedded struct fields (#2868)
- (compiler) Support functions with OUT params (#2865)
- (compiler) Pull in array information from analyzer (#2864)
- (analyzer) Error on unexpanded star expression (#2882)
- (vet) Remove rollback statements from DDL (#2895)
#### Documentation
- Add stable anchors to changelog (#2784)
- Fix typo in v1.22.0 changelog (#2796)
- Add sqlc upload to CI / CD guide (#2797)
- Fix broken link, add clarity to plugins doc (#2813)
- Add clarity and reference to JSON tags (#2819)
- Replace form with dashboard link (#2840)
- (examples) Update examples to use pgx/v5 (#2863)
- Use docker compose v2 and update MYSQL_DATABASE env var (#2870)
- Update getting started guides, use pgx for Postgres guide (#2891)
- Use managed databases in PostgreSQL getting started guide (#2892)
- Update managed databases doc to discuss codegen (#2897)
- Add managed dbs to CI/CD and vet guides (#2896)
- Document database-backed query analyzer (#2904)
#### Features
- (codegen) Support setting Go build tags (#2012) (#2807)
- (generate) Reorder codegen handlers to prefer plugins (#2814)
- (devenv) Add vscode settings.json with auto newline (#2834)
- (cmd) Support sqlc.yml configuration file (#2828)
- (analyzer) Analyze queries using a running PostgreSQL database (#2805)
- (sql/ast) Render AST to SQL (#2815)
- (codegen) Include plugin information (#2846)
- (postgresql) Add ALTER VIEW ... SET SCHEMA (#2855)
- (compiler) Parse query parameter metadata from comments (#2850)
- (postgresql) Support system columns on tables (#2871)
- (compiler) Support LEFT JOIN on aliased table (#2873)
- Improve messaging for common cloud config and rpc errors (#2885)
- Abort compiler when rpc fails as unauthenticated (#2887)
- (codegen) Add support for pgvector and pgvector-go (#2888)
- (analyzer) Cache query analysis (#2889)
- (createdb) Create ephemeral databases (#2894)
- (debug) Add databases=managed debug option (#2898)
- (config) Remove managed database validation (#2901)
#### Miscellaneous Tasks
- (endtoend) Fix test output for do tests (#2782)
#### Refactor
- (codegen) Remove golang and json settings from plugin proto (#2822)
- (codegen) Removed deprecated code and improved speed (#2899)
#### Testing
- (endtoend) Split shema and queries (#2803)
- Fix a few incorrect testcases (#2804)
- (analyzer) Add more database analyzer test cases (#2854)
- Add more analyzer test cases (#2866)
- Add more test cases for new analyzer (#2879)
- (endtoend) Enabled managed-db tests in CI (#2883)
- Enabled pgvector tests for managed dbs (#2893)
#### Build
- (deps) Bump packaging from 23.1 to 23.2 in /docs (#2791)
- (deps) Bump urllib3 from 2.0.5 to 2.0.6 in /docs (#2798)
- (deps) Bump babel from 2.12.1 to 2.13.0 in /docs (#2799)
- (deps) Bump golang.org/x/sync from 0.3.0 to 0.4.0 (#2810)
- (deps) Bump golang from 1.21.1 to 1.21.2 (#2811)
- (deps) Bump github.com/google/go-cmp from 0.5.9 to 0.6.0 (#2826)
- (deps) Bump golang from 1.21.2 to 1.21.3 (#2824)
- (deps) Bump google.golang.org/grpc from 1.58.2 to 1.58.3 (#2825)
- (deps) Bump golang.org/x/net from 0.12.0 to 0.17.0 (#2836)
- (deps) Bump urllib3 from 2.0.6 to 2.0.7 in /docs (#2872)
- (deps) Bump google.golang.org/grpc from 1.58.3 to 1.59.0 (#2876)
- (deps) Upgrade wasmtime-go from 13.0.0 to 14.0.0 (#2900)
#### Ci
- Bump go version in workflows (#2835)
(v1-22-0)=
## [1.22.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.22.0)
Released 2023-09-26
### Release notes
#### Managed databases for `sqlc vet`
If you're using [sqlc vet](../howto/vet.md) to write rules that require access to a running
database, `sqlc` can now start and manage that database for you. PostgreSQL
support is available today, with MySQL on the way.
When you turn on managed databases, `sqlc` will use your schema to create a
template database that it can copy to make future runs of `sqlc vet` very
performant.
This feature relies on configuration obtained via [sqlc
Cloud](https://dashboard.sqlc.dev).
Read more in the [managed databases](../howto/managed-databases.md) documentation.
### Changes
#### Bug Fixes
- (codegen/golang) Refactor imports code to match templates (#2709)
- (codegen/golang) Support name type (#2715)
- (wasm) Move Runner struct to shared file (#2725)
- (engine/sqlite) Fix grammer to avoid missing join_constraint (#2732)
- (convert) Support YAML anchors in plugin options (#2733)
- (mysql) Disallow time.Time in mysql :copyfrom queries, not all queries (#2768)
- (engine/sqlite) Fix convert process for VALUES (#2737)
#### Documentation
- Clarify nullable override behavior (#2753)
- Add managed databases to sidebar (#2764)
- Pull renaming and type overrides into separate sections (#2774)
- Update the docs banner for managed dbs (#2775)
#### Features
- (config) Enables the configuration of copyfrom.go similar to quierer and friends (#2727)
- (vet) Run rules against a managed database (#2751)
- (upload) Point upload command at new endpoint (#2772)
- (compiler) Support DO statements (#2777)
#### Miscellaneous Tasks
- (endtoend) Skip tests missing secrets (#2763)
- Skip certain tests on PRs (#2769)
#### Testing
- (endtoend) Verify all schemas in endtoend (#2744)
- (examples) Use a hosted database for example testing (#2749)
- (endtoend) Pull region from environment (#2750)
#### Build
- (deps) Bump golang from 1.21.0 to 1.21.1 (#2711)
- (deps) Bump google.golang.org/grpc from 1.57.0 to 1.58.1 (#2743)
- (deps) Bump wasmtime-go from v12 to v13 (#2756)
- (windows) Downgrade to mingw 11.2.0 (#2757)
- (deps) Bump urllib3 from 2.0.4 to 2.0.5 in /docs (#2747)
- (deps) Bump google.golang.org/grpc from 1.58.1 to 1.58.2 (#2758)
- (deps) Bump github.com/google/cel-go from 0.18.0 to 0.18.1 (#2778)
#### Ci
- Bump go version to latest in ci workflows (#2722)
(v1-21-0)=
## [1.21.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.21.0)
Released 2023-09-06
### Release notes
This is primarily a bugfix release, along with some documentation and testing improvements.
#### MySQL engine improvements
`sqlc` previously didn't know how to parse a `CALL` statement when using the MySQL engine,
which meant it was impossible to use sqlc with stored procedures in MySQL databases.
Additionally, `sqlc` now supports `IS [NOT] NULL` in queries. And `LIMIT` and `OFFSET` clauses
now work with `UNION`.
#### SQLite engine improvements
GitHub user [@orisano](https://github.com/orisano) continues to bring bugfixes and
improvements to `sqlc`'s SQLite engine. See the "Changes" section below for the
full list.
#### Plugin access to environment variables
If you're authoring a [sqlc plugin](../guides/plugins.html), you can now configure
sqlc to pass your plugin the values of specific environment variables.
For example, if your plugin
needs the `PATH` environment variable, add `PATH` to the `env` list in the
`plugins` collection.
```yaml
version: '2'
sql:
- schema: schema.sql
queries: query.sql
engine: postgresql
codegen:
- out: gen
plugin: test
plugins:
- name: test
env:
- PATH
wasm:
url: https://github.com/sqlc-dev/sqlc-gen-test/releases/download/v0.1.0/sqlc-gen-test.wasm
sha256: 138220eae508d4b65a5a8cea555edd155eb2290daf576b7a8b96949acfeb3790
```
A variable named `SQLC_VERSION` is always included in the plugin's
environment, set to the version of the `sqlc` executable invoking it.
### Changes
#### Bug Fixes
- Myriad string formatting changes (#2558)
- (engine/sqlite) Support quoted identifier (#2556)
- (engine/sqlite) Fix compile error (#2564)
- (engine/sqlite) Fixed detection of column alias without AS (#2560)
- (ci) Bump go version to 1.20.7 (#2568)
- Remove references to deprecated `--experimental` flag (#2567)
- (postgres) Fixed a problem with array dimensions disappearing when using "ALTER TABLE ADD COLUMN" (#2572)
- Remove GitHub sponsor integration (#2574)
- (docs) Improve discussion of prepared statements support (#2604)
- (docs) Remove multidimensional array qualification in datatypes.md (#2619)
- (config) Go struct tag parsing (#2606)
- (compiler) Fix to not scan children under ast.RangeSubselect when retrieving table listing (#2573)
- (engine/sqlite) Support NOT IN (#2587)
- (codegen/golang) Fixed detection of the used package (#2597)
- (engine/dolphin) Fixed problem that LIMIT OFFSET cannot be used with `UNION ALL` (#2613)
- (compiler) Support identifiers with schema (#2579)
- (compiler) Fix column expansion to work with quoted non-keyword identifiers (#2576)
- (codegen/go) Compare define type in codegen (#2263) (#2578)
- (engine/sqlite) Fix ast when using compound operator (#2673)
- (engine/sqlite) Fix to handle join clauses correctly (#2674)
- (codegen) Use correct Go types for bit strings and cid/oid/tid/xid with pgx/v4 (#2668)
- (endtoend) Ensure all SQL works against PostgreSQL (#2684)
#### Documentation
- Update Docker installation instructions (#2552)
- Missing emit_pointers_for_null_types configuration option in version 2 (#2682) (#2683)
- Fix typo (#2697)
- Document sqlc.* macros (#2698)
- (mysql) Document parseTimet=true requirement (#2699)
- Add atlas to the list of supported migration frameworks (#2700)
- Minor updates to insert howto (#2701)
#### Features
- (endtoend/testdata) Added two sqlite `CAST` tests and rearranged postgres tests for same (#2551)
- (docs) Add a reference to type overriding in datatypes.md (#2557)
- (engine/sqlite) Support COLLATE for sqlite WHERE clause (#2554)
- (mysql) Add parser support for IS [NOT] NULL (#2651)
- (engine/dolphin) Support CALL statement (#2614)
- (codegen) Allow plugins to access environment variables (#2669)
- (config) Add JSON schema files for configs (#2703)
#### Miscellaneous Tasks
- Ignore Vim swap files (#2616)
- Fix typo (#2696)
#### Refactor
- (astutils) Remove redundant nil check in `Walk` (#2660)
#### Build
- (deps) Bump wasmtime from v8.0.0 to v11.0.0 (#2553)
- (deps) Bump golang from 1.20.6 to 1.20.7 (#2563)
- (deps) Bump chardet from 5.1.0 to 5.2.0 in /docs (#2562)
- (deps) Bump github.com/pganalyze/pg_query_go/v4 (#2583)
- (deps) Bump golang from 1.20.7 to 1.21.0 (#2596)
- (deps) Bump github.com/jackc/pgx/v5 from 5.4.2 to 5.4.3 (#2582)
- (deps) Bump pygments from 2.15.1 to 2.16.1 in /docs (#2584)
- (deps) Bump sphinxcontrib-applehelp from 1.0.4 to 1.0.7 in /docs (#2620)
- (deps) Bump sphinxcontrib-qthelp from 1.0.3 to 1.0.6 in /docs (#2622)
- (deps) Bump github.com/google/cel-go from 0.17.1 to 0.17.6 (#2650)
- (deps) Bump sphinxcontrib-serializinghtml in /docs (#2641)
- Upgrade from Go 1.20 to Go 1.21 (#2665)
- (deps) Bump sphinxcontrib-devhelp from 1.0.2 to 1.0.5 in /docs (#2621)
- (deps) Bump github.com/bytecodealliance/wasmtime-go from v11.0.0 to v12.0.0 (#2666)
- (deps) Bump sphinx-rtd-theme from 1.2.2 to 1.3.0 in /docs (#2670)
- (deps) Bump sphinxcontrib-htmlhelp from 2.0.1 to 2.0.4 in /docs (#2671)
- (deps) Bump github.com/google/cel-go from 0.17.6 to 0.18.0 (#2691)
- (deps) Bump actions/checkout from 3 to 4 (#2694)
- (deps) Bump pytz from 2023.3 to 2023.3.post1 in /docs (#2695)
- (devenv) Bump go from 1.20.7 to 1.21.0 (#2702)
(v1-20-0)=
## [1.20.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.20.0)
Released 2023-07-31
### Release notes
#### `kyleconroy/sqlc` is now `sqlc-dev/sqlc`
We've completed our migration to the [sqlc-dev/sqlc](https://github.com/sqlc-dev/sqlc) repository. All existing links and installation instructions will continue to work. If you're using the `go` tool to install `sqlc`, you'll need to use the new import path to get v1.20.0 (and all future versions).
```sh
# INCORRECT: old import path
go install github.com/kyleconroy/sqlc/cmd/sqlc@v1.20.0
# CORRECT: new import path
go install github.com/sqlc-dev/sqlc/cmd/sqlc@v1.20.0
```
We designed the upgrade process to be as smooth as possible. If you run into any issues, please [file a bug report](https://github.com/sqlc-dev/sqlc/issues/new?assignees=&labels=bug%2Ctriage&projects=&template=BUG_REPORT.yml) via GitHub.
#### Use `EXPLAIN ...` output in lint rules
`sqlc vet` can now run `EXPLAIN` on your queries and include the results for use in your lint rules. For example, this rule checks that `SELECT` queries use an index.
```yaml
version: 2
sql:
- schema: "query.sql"
queries: "query.sql"
engine: "postgresql"
database:
uri: "postgresql://postgres:postgres@localhost:5432/postgres"
gen:
go:
package: "db"
out: "db"
rules:
- has-index
rules:
- name: has-index
rule: >
query.sql.startsWith("SELECT") &&
!(postgresql.explain.plan.plans.all(p, has(p.index_name) || p.plans.all(p, has(p.index_name))))
```
The expression environment has two variables containing `EXPLAIN ...` output, `postgresql.explain` and `mysql.explain`. `sqlc` only populates the variable associated with your configured database engine, and only when you have a [database connection configured](../reference/config.md#database).
For the `postgresql` engine, `sqlc` runs
```sql
EXPLAIN (ANALYZE false, VERBOSE, COSTS, SETTINGS, BUFFERS, FORMAT JSON) ...
```
where `"..."` is your query string, and parses the output into a [`PostgreSQLExplain`](https://buf.build/sqlc/sqlc/docs/v1.20.0:vet#vet.PostgreSQLExplain) proto message.
For the `mysql` engine, `sqlc` runs
```sql
EXPLAIN FORMAT=JSON ...
```
where `"..."` is your query string, and parses the output into a [`MySQLExplain`](https://buf.build/sqlc/sqlc/docs/v1.20.0:vet#vet.MySQLExplain) proto message.
These proto message definitions are too long to include here, but you can find them in the `protos` directory within the `sqlc` source tree.
The output from `EXPLAIN ...` depends on the structure of your query so it's a bit difficult to offer generic examples. Refer to the [PostgreSQL documentation](https://www.postgresql.org/docs/current/using-explain.html) and [MySQL documentation](https://dev.mysql.com/doc/refman/en/explain-output.html) for more information.
```yaml
...
rules:
- name: postgresql-query-too-costly
message: "Query cost estimate is too high"
rule: "postgresql.explain.plan.total_cost > 1.0"
- name: postgresql-no-seq-scan
message: "Query plan results in a sequential scan"
rule: "postgresql.explain.plan.node_type == 'Seq Scan'"
- name: mysql-query-too-costly
message: "Query cost estimate is too high"
rule: "has(mysql.explain.query_block.cost_info) && double(mysql.explain.query_block.cost_info.query_cost) > 2.0"
- name: mysql-must-use-primary-key
message: "Query plan doesn't use primary key"
rule: "has(mysql.explain.query_block.table.key) && mysql.explain.query_block.table.key != 'PRIMARY'"
```
When building rules that depend on `EXPLAIN ...` output, it may be helpful to see the actual JSON returned from the database. `sqlc` will print it When you set the environment variable `SQLCDEBUG=dumpexplain=1`. Use this environment variable together with a dummy rule to see `EXPLAIN ...` output for all of your queries.
#### Opting-out of lint rules
For any query, you can tell `sqlc vet` not to evaluate lint rules using the `@sqlc-vet-disable` query annotation.
```sql
/* name: GetAuthor :one */
/* @sqlc-vet-disable */
SELECT * FROM authors
WHERE id = ? LIMIT 1;
```
#### Bulk insert for MySQL
_Developed by [@Jille](https://github.com/Jille)_
MySQL now supports the `:copyfrom` query annotation. The generated code uses the [LOAD DATA](https://dev.mysql.com/doc/refman/8.0/en/load-data.html) command to insert data quickly and efficiently.
Use caution with this feature. Errors and duplicate keys are treated as warnings and insertion will continue, even without an error for some cases. Use this in a transaction and use `SHOW WARNINGS` to check for any problems and roll back if necessary.
Check the [error handling](https://dev.mysql.com/doc/refman/8.0/en/load-data.html#load-data-error-handling) documentation for more information.
```sql
CREATE TABLE foo (a text, b integer, c DATETIME, d DATE);
-- name: InsertValues :copyfrom
INSERT INTO foo (a, b, c, d) VALUES (?, ?, ?, ?);
```
```go
func (q *Queries) InsertValues(ctx context.Context, arg []InsertValuesParams) (int64, error) {
...
}
```
`LOAD DATA` support must be enabled in the MySQL server.
#### CAST support for MySQL
_Developed by [@ryanpbrewster](https://github.com/ryanpbrewster) and [@RadhiFadlillah](https://github.com/RadhiFadlillah)_
`sqlc` now understands `CAST` calls in MySQL queries, offering greater flexibility when generating code for complex queries.
```sql
CREATE TABLE foo (bar BOOLEAN NOT NULL);
-- name: SelectColumnCast :many
SELECT CAST(bar AS BIGINT) FROM foo;
```
```go
package querytest
import (
"context"
)
const selectColumnCast = `-- name: SelectColumnCast :many
SELECT CAST(bar AS BIGINT) FROM foo
`
func (q *Queries) SelectColumnCast(ctx context.Context) ([]int64, error) {
...
}
```
#### SQLite improvements
A slew of fixes landed for our SQLite implementation, bringing it closer to parity with MySQL and PostgreSQL. We want to thank [@orisano](https://github.com/orisano) for their continued dedication to improving `sqlc`'s SQLite support.
### Changes
#### Features
- (debug) Add debug flag and docs for dumping vet rule variables (#2521)
- (mysql) :copyfrom support via LOAD DATA INFILE (#2545)
- (mysql) Implement cast function parser (#2473)
- (postgresql) Add support for PostgreSQL multi-dimensional arrays (#2338)
- (sql/catalog) Support ALTER TABLE IF EXISTS (#2542)
- (sqlite) Virtual tables and fts5 supported (#2531)
- (vet) Add default query parameters for explain queries (#2543)
- (vet) Add output from `EXPLAIN ...` for queries to the CEL program environment (#2489)
- (vet) Introduce a query annotation to opt out of sqlc vet rules (#2474)
- Parse comment lines starting with `@symbol` as boolean flags associated with a query (#2464)
#### Bug Fixes
- (codegen/golang) Fix sqlc.embed to work with pq.Array (#2544)
- (compiler) Correctly validate alias in order/group by clauses for joins (#2537)
- (engine/sqlite) Added function to convert cast node (#2470)
- (engine/sqlite) Fix join_operator rule (#2434)
- (engine/sqlite) Fix table_alias rules (#2465)
- (engine/sqlite) Fixed IN operator precedence (#2428)
- (engine/sqlite) Fixed to be able to find relation from WITH clause (#2444)
- (engine/sqlite) Lowercase ast.ResTarget.Name (#2433)
- (engine/sqlite) Put logging statement behind debug flag (#2488)
- (engine/sqlite) Support for repeated table_option (#2482)
- (mysql) Generate unsigned param (#2522)
- (sql/catalog) Support pg_dump output (#2508)
- (sqlite) Code generation for sqlc.slice (#2431)
- (vet) Clean up unnecessary `prepareable()` func and a var name (#2509)
- (vet) Query.cmd was always set to ":" (#2525)
- (vet) Report an error when a query is unpreparable, close prepared statement connection (#2486)
- (vet) Split vet messages out of codegen.proto (#2511)
#### Documentation
- Add a description to the document for cases when a query result has no rows (#2462)
- Update copyright and author (#2490)
- Add example sqlc.yaml for migration parsing (#2479)
- Small updates (#2506)
- Point GitHub links to new repository location (#2534)
#### Miscellaneous Tasks
- Rename kyleconroy/sqlc to sqlc-dev/sqlc (#2523)
- (proto) Reformat protos using `buf format -w` (#2536)
- Update FEATURE_REQUEST.yml to include SQLite engine option
- Finish migration to sqlc-dev/sqlc (#2548)
- (compiler) Remove some duplicate code (#2546)
#### Testing
- Add profiles to docker compose (#2503)
#### Build
- Run all supported versions of MySQL / PostgreSQL (#2463)
- (deps) Bump pygments from 2.7.4 to 2.15.0 in /docs (#2485)
- (deps) Bump github.com/jackc/pgconn from 1.14.0 to 1.14.1 (#2483)
- (deps) Bump github.com/google/cel-go from 0.16.0 to 0.17.1 (#2484)
- (docs) Check Python dependencies via dependabot (#2497)
- (deps) Bump idna from 2.10 to 3.4 in /docs (#2499)
- (deps) Bump packaging from 20.9 to 23.1 in /docs (#2498)
- (deps) Bump pygments from 2.15.0 to 2.15.1 in /docs (#2500)
- (deps) Bump certifi from 2022.12.7 to 2023.7.22 in /docs (#2504)
- (deps) Bump sphinx from 4.4.0 to 6.1.0 in /docs (#2505)
- Add psql and mysqlsh to devenv (#2507)
- (deps) Bump urllib3 from 1.26.5 to 2.0.4 in /docs (#2516)
- (deps) Bump chardet from 4.0.0 to 5.1.0 in /docs (#2517)
- (deps) Bump snowballstemmer from 2.1.0 to 2.2.0 in /docs (#2519)
- (deps) Bump pytz from 2021.1 to 2023.3 in /docs (#2520)
- (deps) Bump sphinxcontrib-htmlhelp from 2.0.0 to 2.0.1 in /docs (#2518)
- (deps) Bump pyparsing from 2.4.7 to 3.1.0 in /docs (#2530)
- (deps) Bump alabaster from 0.7.12 to 0.7.13 in /docs (#2526)
- (docs) Ignore updates for sphinx (#2532)
- (deps) Bump babel from 2.9.1 to 2.12.1 in /docs (#2527)
- (deps) Bump sphinxcontrib-applehelp from 1.0.2 to 1.0.4 in /docs (#2533)
- (deps) Bump google.golang.org/grpc from 1.56.2 to 1.57.0 (#2535)
- (deps) Bump pyparsing from 3.1.0 to 3.1.1 in /docs (#2547)
## [1.19.1](https://github.com/sqlc-dev/sqlc/releases/tag/v1.19.1)
Released 2023-07-13
### Bug Fixes
- Fix to traverse Sel in ast.In (#2414)
- (compiler) Validate UNION ... ORDER BY (#2446)
- (golang) Prevent duplicate enum output (#2447)
### Miscellaneous Tasks
- Replace codegen, test and docs references to github.com/tabbed repos (#2418)
### Build
- (deps) Bump google.golang.org/grpc from 1.56.1 to 1.56.2 (#2415)
- (deps) Bump golang from 1.20.5 to 1.20.6 (#2437)
- Pin Go to 1.20.6 (#2441)
- (deps) Bump github.com/jackc/pgx/v5 from 5.4.1 to 5.4.2 (#2436)
## [1.19.0](https://github.com/sqlc-dev/sqlc/releases/tag/v1.19.0)
Released 2023-07-06
### Release notes
#### sqlc vet
[`sqlc vet`](../howto/vet.md) runs queries through a set of lint rules.
Rules are defined in the `sqlc` [configuration](config.md) file. They consist
of a name, message, and a [Common Expression Language (CEL)](https://github.com/google/cel-spec)
expression. Expressions are evaluated using [cel-go](https://github.com/google/cel-go).
If an expression evaluates to `true`, an error is reported using the given message.
While these examples are simplistic, they give you a flavor of the types of
rules you can write.
```yaml
version: 2
sql:
- schema: "query.sql"
queries: "query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
rules:
- no-pg
- no-delete
- only-one-param
- no-exec
rules:
- name: no-pg
message: "invalid engine: postgresql"
rule: |
config.engine == "postgresql"
- name: no-delete
message: "don't use delete statements"
rule: |
query.sql.contains("DELETE")
- name: only-one-param
message: "too many parameters"
rule: |
query.params.size() > 1
- name: no-exec
message: "don't use exec"
rule: |
query.cmd == "exec"
```
##### Database connectivity
`vet` also marks the first time that `sqlc` can connect to a live, running
database server. We'll expand this functionality over time, but for now it
powers the `sqlc/db-prepare` built-in rule.
When a [database](config.html#database) is configured, the
`sqlc/db-preapre` rule will attempt to prepare each of your
queries against the connected database and report any failures.
```yaml
version: 2
sql:
- schema: "query.sql"
queries: "query.sql"
engine: "postgresql"
gen:
go:
package: "authors"
out: "db"
database:
uri: "postgresql://postgres:password@localhost:5432/postgres"
rules:
- sqlc/db-prepare
```
To see this in action, check out the [authors
example](https://github.com/sqlc-dev/sqlc/blob/main/examples/authors/sqlc.yaml).
Please note that `sqlc` does not manage or migrate your database. Use your
migration tool of choice to create the necessary database tables and objects
before running `sqlc vet`.
#### Omit unused structs
Added a new configuration parameter `omit_unused_structs` which, when set to
true, filters out table and enum structs that aren't used in queries for a given
package.
#### Suggested CI/CD setup
With the addition of `sqlc diff` and `sqlc vet`, we encourage users to run sqlc
in your CI/CD pipelines. See our [suggested CI/CD setup](../howto/ci-cd.md) for
more information.
#### Simplified plugin development
The [sqlc-gen-kotlin](https://github.com/sqlc-dev/sqlc-gen-kotlin) and
[sqlc-gen-python](https://github.com/sqlc-dev/sqlc-gen-python) plugins have been
updated use the upcoming [WASI](https://wasi.dev/) support in [Go
1.21](https://tip.golang.org/doc/go1.21#wasip1). Building these plugins no
longer requires [TinyGo](https://tinygo.org/).
### Changes
#### Bug Fixes
- Pointers overrides skip imports in generated query files (#2240)
- CASE-ELSE clause is not properly parsed when a value is constant (#2238)
- Fix toSnakeCase to handle input in CamelCase format (#2245)
- Add location info to sqlite ast (#2298)
- Add override tags to result struct (#1867) (#1887)
- Override types of aliased columns and named parameters (#1884)
- Resolve duplicate fields generated when inheriting multiple tables (#2089)
- Check column references in ORDER BY (#1411) (#1915)
- MySQL slice shadowing database/sql import (#2332)
- Don't defer rows.Close() if pgx.BatchResults.Query() failed (#2362)
- Fix type overrides not working with sqlc.slice (#2351)
- Type overrides on columns for parameters inside an IN clause (#2352)
- Broken interaction between query_parameter_limit and pq.Array() (#2383)
- (codegen/golang) Bring :execlastid in line with the rest (#2378)
#### Documentation
- Update changelog.md with some minor edits (#2235)
- Add F# community plugin (#2295)
- Add a ReadTheDocs config file (#2327)
- Update query_parameter_limit documentation (#2374)
- Add launch announcement banner
#### Features
- PostgreSQL capture correct line and column numbers for parse error (#2289)
- Add supporting COMMENT ON VIEW (#2249)
- To allow spaces between function name and arguments of functions to be rewritten (#2250)
- Add support for pgx/v5 emit_pointers_for_null_types flag (#2269)
- (mysql) Support unsigned integers (#1746)
- Allow use of table and column aliases for table functions returning unknown types (#2156)
- Support "LIMIT ?" in UPDATE and DELETE for MySQL (#2365)
- (internal/codegen/golang) Omit unused structs from output (#2369)
- Improve default names for BETWEEN ? AND ? to have prefixes from_ and to_ (#2366)
- (cmd/sqlc) Add the vet subcommand (#2344)
- (sqlite) Add support for UPDATE/DELETE with a LIMIT clause (#2384)
- Add support for BETWEEN sqlc.arg(min) AND sqlc.arg(max) (#2373)
- (cmd/vet) Prepare queries against a database (#2387)
- (cmd/vet) Prepare queries for MySQL (#2388)
- (cmd/vet) Prepare SQLite queries (#2389)
- (cmd/vet) Simplify environment variable substiution (#2393)
- (cmd/vet) Add built-in db-prepare rule
- Add compiler support for NOTIFY and LISTEN (PostgreSQL) (#2363)
#### Miscellaneous Tasks
- A few small staticcheck fixes (#2361)
- Remove a bunch of dead code (#2360)
- (scripts/regenerate) Should also update stderr.txt (#2379)
#### Build
- (deps) Bump requests from 2.25.1 to 2.31.0 in /docs (#2283)
- (deps) Bump golang from 1.20.3 to 1.20.4 (#2256)
- (deps) Bump google.golang.org/grpc from 1.54.0 to 1.55.0 (#2265)
- (deps) Bump github.com/mattn/go-sqlite3 from 1.14.16 to 1.14.17 (#2293)
- (deps) Bump golang.org/x/sync from 0.1.0 to 0.2.0 (#2266)
- (deps) Bump golang from 1.20.4 to 1.20.5 (#2301)
- Configure dependencies via devenv.sh (#2319)
- Configure dependencies via devenv.sh (#2326)
- (deps) Bump golang.org/x/sync from 0.2.0 to 0.3.0 (#2328)
- (deps) Bump google.golang.org/grpc from 1.55.0 to 1.56.0 (#2333)
- (deps) Bump google.golang.org/protobuf from 1.30.0 to 1.31.0 (#2370)
- (deps) Bump actions/checkout from 2 to 3 (#2357)
- Run govulncheck on all builds (#2372)
- (deps) Bump google.golang.org/grpc from 1.56.0 to 1.56.1 (#2358)
#### Cmd/sqlc
- Show helpful output on missing subcommand (#2345)
#### Codegen
- Use catalog's default schema (#2310)
- (go) Add tests for tables with dashes (#2312)
- (go) Strip invalid characters from table and column names (
Showing preview only (343K chars total). Download the full file or copy to clipboard to get everything.
gitextract_4y3p3xpd/ ├── .github/ │ ├── ISSUE_TEMPLATE/ │ │ ├── BUG_REPORT.yml │ │ └── FEATURE_REQUEST.yml │ ├── dependabot.yml │ └── workflows/ │ ├── buf.yml │ ├── build.yml │ ├── ci-kotlin.yml │ ├── ci-python.yml │ ├── ci-typescript.yml │ ├── ci.yml │ └── gen.yml ├── .gitignore ├── .readthedocs.yaml ├── .vscode/ │ └── settings.json ├── CLAUDE.md ├── Dockerfile ├── LICENSE ├── Makefile ├── README.md ├── buf.gen.yaml ├── buf.work.yaml ├── cliff.toml ├── cmd/ │ ├── sqlc/ │ │ └── main.go │ ├── sqlc-gen-json/ │ │ └── main.go │ └── sqlc-test-setup/ │ └── main.go ├── devenv.nix ├── devenv.yaml ├── docker-compose.yml ├── docs/ │ ├── .gitignore │ ├── Makefile │ ├── _static/ │ │ └── customize.css │ ├── _templates/ │ │ ├── breadcrumbs.html │ │ └── layout.html │ ├── conf.py │ ├── guides/ │ │ ├── development.md │ │ ├── migrating-off-hosted-managed-databases.md │ │ ├── migrating-to-sqlc-gen-kotlin.md │ │ ├── migrating-to-sqlc-gen-python.md │ │ ├── plugins.md │ │ ├── privacy.md │ │ └── using-go-and-pgx.rst │ ├── howto/ │ │ ├── ci-cd.md │ │ ├── ddl.md │ │ ├── delete.md │ │ ├── embedding.md │ │ ├── generate.md │ │ ├── insert.md │ │ ├── managed-databases.md │ │ ├── named_parameters.md │ │ ├── overrides.md │ │ ├── prepared_query.md │ │ ├── push.md │ │ ├── query_count.md │ │ ├── rename.md │ │ ├── select.md │ │ ├── structs.md │ │ ├── transactions.md │ │ ├── update.md │ │ ├── verify.md │ │ └── vet.md │ ├── index.rst │ ├── overview/ │ │ └── install.md │ ├── reference/ │ │ ├── changelog.md │ │ ├── cli.md │ │ ├── config.md │ │ ├── datatypes.md │ │ ├── environment-variables.md │ │ ├── language-support.rst │ │ ├── macros.md │ │ └── query-annotations.md │ ├── requirements.txt │ └── tutorials/ │ ├── getting-started-mysql.md │ ├── getting-started-postgresql.md │ └── getting-started-sqlite.md ├── examples/ │ ├── authors/ │ │ ├── mysql/ │ │ │ ├── db.go │ │ │ ├── db_test.go │ │ │ ├── models.go │ │ │ ├── query.sql │ │ │ ├── query.sql.go │ │ │ └── schema.sql │ │ ├── postgresql/ │ │ │ ├── db.go │ │ │ ├── db_test.go │ │ │ ├── models.go │ │ │ ├── query.sql │ │ │ ├── query.sql.go │ │ │ └── schema.sql │ │ ├── sqlc.yaml │ │ └── sqlite/ │ │ ├── db.go │ │ ├── db_test.go │ │ ├── models.go │ │ ├── query.sql │ │ ├── query.sql.go │ │ └── schema.sql │ ├── batch/ │ │ ├── postgresql/ │ │ │ ├── batch.go │ │ │ ├── db.go │ │ │ ├── db_test.go │ │ │ ├── models.go │ │ │ ├── querier.go │ │ │ ├── query.sql │ │ │ ├── query.sql.go │ │ │ └── schema.sql │ │ └── sqlc.json │ ├── booktest/ │ │ ├── mysql/ │ │ │ ├── db.go │ │ │ ├── db_test.go │ │ │ ├── models.go │ │ │ ├── query.sql │ │ │ ├── query.sql.go │ │ │ └── schema.sql │ │ ├── postgresql/ │ │ │ ├── db.go │ │ │ ├── db_test.go │ │ │ ├── models.go │ │ │ ├── query.sql │ │ │ ├── query.sql.go │ │ │ └── schema.sql │ │ ├── sqlc.json │ │ └── sqlite/ │ │ ├── db.go │ │ ├── db_test.go │ │ ├── models.go │ │ ├── query.sql │ │ ├── query.sql.go │ │ └── schema.sql │ ├── jets/ │ │ ├── README.md │ │ ├── postgresql/ │ │ │ ├── db.go │ │ │ ├── models.go │ │ │ ├── query-building.sql │ │ │ ├── query-building.sql.go │ │ │ └── schema.sql │ │ └── sqlc.json │ └── ondeck/ │ ├── mysql/ │ │ ├── city.sql.go │ │ ├── db.go │ │ ├── db_test.go │ │ ├── models.go │ │ ├── querier.go │ │ ├── query/ │ │ │ ├── city.sql │ │ │ └── venue.sql │ │ ├── schema/ │ │ │ ├── 0001_city.sql │ │ │ ├── 0002_venue.sql │ │ │ └── 0003_add_column.sql │ │ └── venue.sql.go │ ├── postgresql/ │ │ ├── city.sql.go │ │ ├── db.go │ │ ├── db_test.go │ │ ├── models.go │ │ ├── querier.go │ │ ├── query/ │ │ │ ├── city.sql │ │ │ └── venue.sql │ │ ├── schema/ │ │ │ ├── 0001_city.sql │ │ │ ├── 0002_venue.sql │ │ │ └── 0003_add_column.sql │ │ └── venue.sql.go │ ├── sqlc.json │ └── sqlite/ │ ├── city.sql.go │ ├── db.go │ ├── db_test.go │ ├── models.go │ ├── querier.go │ ├── query/ │ │ ├── city.sql │ │ └── venue.sql │ ├── schema/ │ │ ├── 0001_city.sql │ │ ├── 0002_venue.sql │ │ └── 0003_add_column.sql │ └── venue.sql.go ├── go.mod ├── go.sum ├── internal/ │ ├── analysis/ │ │ ├── analysis.pb.go │ │ └── analysis_vtproto.pb.go │ ├── analyzer/ │ │ └── analyzer.go │ ├── bundler/ │ │ ├── multipart.go │ │ └── upload.go │ ├── cache/ │ │ └── cache.go │ ├── cmd/ │ │ ├── cmd.go │ │ ├── createdb.go │ │ ├── diff.go │ │ ├── generate.go │ │ ├── options.go │ │ ├── parse.go │ │ ├── process.go │ │ ├── push.go │ │ ├── shim.go │ │ ├── verify.go │ │ ├── vet.go │ │ └── vet_sqlite.go │ ├── codegen/ │ │ ├── golang/ │ │ │ ├── driver.go │ │ │ ├── enum.go │ │ │ ├── field.go │ │ │ ├── gen.go │ │ │ ├── go_type.go │ │ │ ├── imports.go │ │ │ ├── mysql_type.go │ │ │ ├── opts/ │ │ │ │ ├── enum.go │ │ │ │ ├── go_type.go │ │ │ │ ├── options.go │ │ │ │ ├── override.go │ │ │ │ ├── override_test.go │ │ │ │ └── shim.go │ │ │ ├── postgresql_type.go │ │ │ ├── query.go │ │ │ ├── reserved.go │ │ │ ├── result.go │ │ │ ├── result_test.go │ │ │ ├── sqlite_type.go │ │ │ ├── struct.go │ │ │ ├── template.go │ │ │ └── templates/ │ │ │ ├── go-sql-driver-mysql/ │ │ │ │ └── copyfromCopy.tmpl │ │ │ ├── pgx/ │ │ │ │ ├── batchCode.tmpl │ │ │ │ ├── copyfromCopy.tmpl │ │ │ │ ├── dbCode.tmpl │ │ │ │ ├── interfaceCode.tmpl │ │ │ │ └── queryCode.tmpl │ │ │ ├── stdlib/ │ │ │ │ ├── dbCode.tmpl │ │ │ │ ├── interfaceCode.tmpl │ │ │ │ └── queryCode.tmpl │ │ │ └── template.tmpl │ │ ├── json/ │ │ │ ├── gen.go │ │ │ └── opts.go │ │ └── sdk/ │ │ ├── sdk.go │ │ ├── utils.go │ │ └── utils_test.go │ ├── compiler/ │ │ ├── analyze.go │ │ ├── compat.go │ │ ├── compile.go │ │ ├── engine.go │ │ ├── expand.go │ │ ├── find_params.go │ │ ├── output_columns.go │ │ ├── parse.go │ │ ├── query.go │ │ ├── query_catalog.go │ │ ├── resolve.go │ │ ├── result.go │ │ ├── selector.go │ │ ├── selector_test.go │ │ └── to_column.go │ ├── config/ │ │ ├── config.go │ │ ├── config_test.go │ │ ├── convert/ │ │ │ ├── convert.go │ │ │ └── convert_test.go │ │ ├── env.go │ │ ├── v_one.go │ │ ├── v_one.json │ │ ├── v_two.go │ │ ├── v_two.json │ │ └── validate.go │ ├── constants/ │ │ └── query.go │ ├── dbmanager/ │ │ └── client.go │ ├── debug/ │ │ └── dump.go │ ├── endtoend/ │ │ ├── CLAUDE.md │ │ ├── case_test.go │ │ ├── ddl_test.go │ │ ├── endtoend_test.go │ │ ├── fmt_test.go │ │ ├── json_schema_test.go │ │ ├── testdata/ │ │ │ ├── accurate_cte/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── accurate_enum/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── accurate_sqlite/ │ │ │ │ └── sqlite/ │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── accurate_star_expansion/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── alias/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── any/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── array_in/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── array_text/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── array_text_join/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── bad_config/ │ │ │ │ └── engine/ │ │ │ │ ├── query.sql │ │ │ │ ├── sqlc.yaml │ │ │ │ └── stderr.txt │ │ │ ├── batch/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── batch.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── batch.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── batch_imports/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── batch.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── batch.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── batch_parameter_limit/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── batch.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── batch_parameter_type/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── batch.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── between_args/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── bit_string/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── build_tags/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── builtins/ │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── aggfunc.sql.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── mathfunc.sql.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── scalarfunc.sql.go │ │ │ │ ├── queries/ │ │ │ │ │ ├── aggfunc.sql │ │ │ │ │ ├── mathfunc.sql │ │ │ │ │ └── scalarfunc.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── case_named_params/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── case_sensitive/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── case_stmt_bool/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── case_text/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── case_value_param/ │ │ │ │ ├── issue.md │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.yaml │ │ │ │ └── postgresql/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cast_coalesce/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cast_null/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cast_param/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cid_oid_tid_xid/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── citext/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── coalesce/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── coalesce_as/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pganalyze/ │ │ │ │ │ │ ├── exec.json │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── exec.json │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── exec.json │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── coalesce_join/ │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── coalesce_params/ │ │ │ │ ├── issue.md │ │ │ │ └── mysql/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── codegen_json/ │ │ │ │ ├── exec.json │ │ │ │ ├── gen/ │ │ │ │ │ └── codegen.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── query.sql │ │ │ │ │ └── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── codegen_struct_field_names/ │ │ │ │ └── stdlib/ │ │ │ │ ├── README.md │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── column_alias/ │ │ │ │ ├── issue.md │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── column_as/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── comment_godoc/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── comment_godoc_db_argument/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── comment_on/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── comment_syntax/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── comparisons/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── composite_type/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── conflicted_arg_name/ │ │ │ │ └── postgresql/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── copyfrom/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── copyfrom_imports/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── copyfrom_multicolumn_parameter_limit/ │ │ │ │ └── mysql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── copyfrom_named_params/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── copyfrom_singlecolumn/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── copyfrom_singlecolumn_struct_only/ │ │ │ │ ├── issue.md │ │ │ │ └── mysql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── count_star/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── create_materialized_view/ │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── create_table_as/ │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── create_table_like/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── create_view/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cte_count/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cte_filter/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cte_in_delete/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cte_join_self/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_left_join/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_multiple_alias/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_nested_with/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_recursive/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── cte_recursive_employees/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_recursive_star/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_recursive_subquery/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_recursive_union/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_select_one/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_update/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_update_multiple/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── cte_with_in/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pganalyze/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── data_type_boolean/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── db/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── datatype/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── sql/ │ │ │ │ │ │ ├── character.sql │ │ │ │ │ │ ├── datetime.sql │ │ │ │ │ │ ├── numeric.sql │ │ │ │ │ │ └── query.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── sql/ │ │ │ │ │ │ │ ├── character.sql │ │ │ │ │ │ │ ├── datetime.sql │ │ │ │ │ │ │ ├── net-types.sql │ │ │ │ │ │ │ ├── numeric.sql │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ └── rangetypes.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── sql/ │ │ │ │ │ │ ├── character.sql │ │ │ │ │ │ ├── datetime.sql │ │ │ │ │ │ ├── net-types.sql │ │ │ │ │ │ ├── numeric.sql │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ └── rangetypes.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── sqlite/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── sql/ │ │ │ │ │ │ ├── character.sql │ │ │ │ │ │ ├── datetime.sql │ │ │ │ │ │ ├── numeric.sql │ │ │ │ │ │ └── query.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── sql/ │ │ │ │ │ ├── character.sql │ │ │ │ │ ├── datetime.sql │ │ │ │ │ ├── net-types.sql │ │ │ │ │ ├── numeric.sql │ │ │ │ │ ├── query.sql │ │ │ │ │ └── rangetypes.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_materialized_views_set_schema/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── ddl_alter_table_add_column/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_add_column_if_not_exists/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_alter_type/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_case_sensitivity/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_change_column/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_column_drop_not_null/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_drop_column/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_drop_column_if_exists/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_drop_constraint/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_if_exists/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_index/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_rename/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_rename_column/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_set_data_type/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_set_not_null/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_table_set_schema/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_type_add_value/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_type_rename/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_type_rename_and_update_columns/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_type_rename_value/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_alter_type_set_schema/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_comment/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── README.md │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_enum/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_func_exists/ │ │ │ │ ├── exec.json │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ ├── query.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── ddl_create_function/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_function_args/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_function_return/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_function_types/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_procedure/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table_include/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table_inherits/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table_invalid_inherits/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── ddl_create_table_like/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── ddl_create_table_partition/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table_reserved/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table_strict/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_table_unknown_type/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.yaml │ │ │ │ └── stderr.txt │ │ │ ├── ddl_create_table_without_rowid/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_create_trigger/ │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_function/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_function_args/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_function_if_exists/ │ │ │ │ ├── mysql/ │ │ │ │ │ └── README.md │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_schema/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_schema_if_exists/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_table/ │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_table_if_exists/ │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_table_in_schema/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_type/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_type_if_exists/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_drop_type_in_schema/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_generated_columns/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_materialized_views_invalid/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.yaml │ │ │ │ └── stderr.txt │ │ │ ├── ddl_pg_temp/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── ddl_rename_drop_materialized_views/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.yaml │ │ │ │ └── v5/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── delete_from/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── delete_inner_join/ │ │ │ │ └── mysql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── delete_join/ │ │ │ │ └── mysql/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── delete_using/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── diff_no_output/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── diff_output/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── do/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── db/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── pq/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── duplicate_go_names/ │ │ │ │ ├── enum/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.yaml │ │ │ │ │ └── stderr.txt │ │ │ │ ├── null_enum/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.yaml │ │ │ │ │ └── stderr.txt │ │ │ │ └── query_constant/ │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.yaml │ │ │ │ └── stderr.txt │ │ │ ├── emit_db_and_json_tags/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_db_tags/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_empty_slices/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_enum_valid_and_values/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_exported_queries/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_methods_with_db_argument/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_pointers_for_null_types/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── sql/ │ │ │ │ │ │ │ ├── character.sql │ │ │ │ │ │ │ ├── datetime.sql │ │ │ │ │ │ │ ├── net-types.sql │ │ │ │ │ │ │ ├── numeric.sql │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ └── rangetypes.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── sql/ │ │ │ │ │ │ ├── character.sql │ │ │ │ │ │ ├── datetime.sql │ │ │ │ │ │ ├── net-types.sql │ │ │ │ │ │ ├── numeric.sql │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ └── rangetypes.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── sqlite/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── sql/ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ └── types.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── sql/ │ │ │ │ │ ├── character.sql │ │ │ │ │ ├── datetime.sql │ │ │ │ │ ├── net-types.sql │ │ │ │ │ ├── numeric.sql │ │ │ │ │ ├── query.sql │ │ │ │ │ └── rangetypes.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_result_and_params_struct_pointers/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── batch.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── batch.go │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── emit_sql_as_comment/ │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── enum/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── enum_column/ │ │ │ │ ├── issue.md │ │ │ │ └── mysql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── enum_ordering/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── exec_create_table/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── db/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── mysql.query.sql.go │ │ │ │ │ ├── mysql.query.sql │ │ │ │ │ ├── mysql.schema.sql │ │ │ │ │ └── sqlc.yaml │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── db/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── postgresql.query.sql.go │ │ │ │ │ ├── postgresql.query.sql │ │ │ │ │ ├── postgresql.schema.sql │ │ │ │ │ └── sqlc.yaml │ │ │ │ └── sqlite/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── sqlite.query.sql.go │ │ │ │ ├── sqlc.yaml │ │ │ │ ├── sqlite.query.sql │ │ │ │ └── sqlite.schema.sql │ │ │ ├── exec_imports/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── exec_lastid/ │ │ │ │ └── go_postgresql_stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── exec_no_return_struct/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── exec_result/ │ │ │ │ ├── go_postgresql_pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── go_postgresql_stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── exec_rows/ │ │ │ │ ├── go_postgresql_pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ ├── querier.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── go_postgresql_stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ ├── querier.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── full_outer_join/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_aggregate/ │ │ │ │ ├── pganalyze/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_args/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_args_typecast/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_call_cast/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_match_types/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_out_param/ │ │ │ │ ├── issue.md │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── func_return_date/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pganalyze/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pgx/ │ │ │ │ │ └── v5/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_return_record/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── func_return_series/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── func_return_table/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── func_return_table_columns/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── func_star_expansion/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── func_variadic/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── geometric/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── go.mod │ │ │ ├── go.sum │ │ │ ├── golang_initialisms_empty/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── golang_initialisms_url/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── golang_invalid_sql_driver/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── golang_invalid_sql_package/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── having/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── hstore/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── hstore.sql.go │ │ │ │ │ │ │ └── models.go │ │ │ │ │ │ ├── hstore.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── hstore.sql.go │ │ │ │ │ │ └── models.go │ │ │ │ │ ├── hstore.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── hstore.sql.go │ │ │ │ │ └── models.go │ │ │ │ ├── hstore.sql │ │ │ │ └── sqlc.json │ │ │ ├── identical_tables/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── identifier_case_sensitivity/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── identifier_dollar_sign/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── in_union/ │ │ │ │ └── mysql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── inflection/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── inflection_exclude_table_names/ │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── v4/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── v5/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── insert_cte/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── insert_default_values/ │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── insert_select/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── insert_select_case/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── insert_select_invalid/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr.txt │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ ├── sqlc.json │ │ │ │ │ │ │ └── stderr/ │ │ │ │ │ │ │ ├── base.txt │ │ │ │ │ │ │ └── managed-db.txt │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ ├── sqlc.json │ │ │ │ │ │ └── stderr/ │ │ │ │ │ │ ├── base.txt │ │ │ │ │ │ └── managed-db.txt │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr/ │ │ │ │ │ ├── base.txt │ │ │ │ │ └── managed-db.txt │ │ │ │ └── sqlite/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── insert_select_param/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── insert_values/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── insert_values_only/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── insert_values_public/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── interval/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── exec.json │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── invalid_func_args/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ ├── sqlc.json │ │ │ │ │ │ └── stderr/ │ │ │ │ │ │ ├── base.txt │ │ │ │ │ │ └── managed-db.txt │ │ │ │ │ └── v5/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr/ │ │ │ │ │ ├── base.txt │ │ │ │ │ └── managed-db.txt │ │ │ │ └── stdlib/ │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr/ │ │ │ │ ├── base.txt │ │ │ │ └── managed-db.txt │ │ │ ├── invalid_group_by_reference/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr.txt │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr/ │ │ │ │ │ ├── base.txt │ │ │ │ │ └── managed-db.txt │ │ │ │ └── sqlite/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── invalid_insert_unknown_column/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── db/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── invalid_named_params/ │ │ │ │ └── mysql/ │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── invalid_params/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ ├── sqlc.json │ │ │ │ │ │ └── stderr/ │ │ │ │ │ │ ├── base.txt │ │ │ │ │ │ └── managed-db.txt │ │ │ │ │ └── v5/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr/ │ │ │ │ │ ├── base.txt │ │ │ │ │ └── managed-db.txt │ │ │ │ └── stdlib/ │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr/ │ │ │ │ ├── base.txt │ │ │ │ └── managed-db.txt │ │ │ ├── invalid_params_type_mismatch/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── invalid_queries_bar/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ ├── sqlc.json │ │ │ │ │ │ └── stderr/ │ │ │ │ │ │ ├── base.txt │ │ │ │ │ │ └── managed-db.txt │ │ │ │ │ └── v5/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr/ │ │ │ │ │ ├── base.txt │ │ │ │ │ └── managed-db.txt │ │ │ │ └── stdlib/ │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr/ │ │ │ │ ├── base.txt │ │ │ │ └── managed-db.txt │ │ │ ├── invalid_queries_foo/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ ├── sqlc.json │ │ │ │ │ │ └── stderr.txt │ │ │ │ │ └── v5/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr.txt │ │ │ │ └── stdlib/ │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── invalid_table_alias/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr.txt │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ ├── sqlc.json │ │ │ │ │ └── stderr/ │ │ │ │ │ ├── base.txt │ │ │ │ │ └── managed-db.txt │ │ │ │ └── sqlite/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.json │ │ │ │ └── stderr.txt │ │ │ ├── invalid_update_unknown_column/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.yaml │ │ │ │ └── stderr.txt │ │ │ ├── join_alias/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_clauses_order/ │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_from/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_full/ │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_group_by_alias/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_inner/ │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_left/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_left_same_table/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgres/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_left_table_alias/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── join_order_by/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── join_order_by_alias/ │ │ │ │ └── postgresql/ │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_right/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_table_name/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_two_tables/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── join_update/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── join_using/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── join_validate_columns/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ ├── sqlc.yaml │ │ │ │ └── stderr.txt │ │ │ ├── join_where_clause/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── json/ │ │ │ │ ├── mysql/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── copyfrom.go │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── json_array_elements/ │ │ │ │ ├── issue.md │ │ │ │ └── postgresql/ │ │ │ │ └── pgx/ │ │ │ │ ├── exec.json │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── json_build/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── json_param_type/ │ │ │ │ ├── issue.md │ │ │ │ ├── postgresql/ │ │ │ │ │ └── pgx/ │ │ │ │ │ ├── exec.json │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.yaml │ │ │ │ └── sqlite/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.yaml │ │ │ ├── json_tags/ │ │ │ │ ├── camel_case/ │ │ │ │ │ └── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── pascal_case/ │ │ │ │ │ └── postgresql/ │ │ │ │ │ ├── pgx/ │ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ │ └── v5/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── snake_case/ │ │ │ │ └── postgresql/ │ │ │ │ ├── pgx/ │ │ │ │ │ ├── v4/ │ │ │ │ │ │ ├── go/ │ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ │ ├── query.sql │ │ │ │ │ │ ├── schema.sql │ │ │ │ │ │ └── sqlc.json │ │ │ │ │ └── v5/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ └── stdlib/ │ │ │ │ ├── go/ │ │ │ │ │ ├── db.go │ │ │ │ │ ├── models.go │ │ │ │ │ └── query.sql.go │ │ │ │ ├── query.sql │ │ │ │ ├── schema.sql │ │ │ │ └── sqlc.json │ │ │ ├── json_tags_null_enum/ │ │ │ │ ├── camel_case/ │ │ │ │ │ └── postgresql/ │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── models.go │ │ │ │ │ │ └── query.sql.go │ │ │ │ │ ├── query.sql │ │ │ │ │ ├── schema.sql │ │ │ │ │ └── sqlc.json │ │ │ │ ├── none/ │ │ │ │ │ └── postgresql/ │ │ │ │ │ └── stdlib/ │ │ │ │ │ ├── go/ │ │ │ │ │ │ ├── db.go │ │ │ │ │ │ ├── model
Showing preview only (1,661K chars total). Download the full file or copy to clipboard to get everything.
SYMBOL INDEX (17482 symbols across 4109 files)
FILE: cmd/sqlc-gen-json/main.go
function main (line 15) | func main() {
function run (line 22) | func run() error {
FILE: cmd/sqlc-test-setup/main.go
constant pgVersion (line 20) | pgVersion = "18.2.0"
type pgBinary (line 24) | type pgBinary struct
function main (line 41) | func main() {
function run (line 66) | func run(name string, args ...string) error {
function runOutput (line 76) | func runOutput(name string, args ...string) (string, error) {
function commandExists (line 84) | func commandExists(name string) bool {
function isMySQLVersionOK (line 91) | func isMySQLVersionOK(versionOutput string) bool {
function pgBaseDir (line 111) | func pgBaseDir() string {
function pgBinDir (line 120) | func pgBinDir() string {
function pgDataDir (line 125) | func pgDataDir() string {
function pgBin (line 130) | func pgBin(name string) string {
function runInstall (line 136) | func runInstall() error {
function installAptProxy (line 155) | func installAptProxy() error {
function installPostgreSQL (line 174) | func installPostgreSQL() error {
function installPgDeps (line 250) | func installPgDeps() error {
function supportedPlatforms (line 259) | func supportedPlatforms() string {
function downloadFile (line 268) | func downloadFile(filepath string, url string) error {
function sha256File (line 290) | func sha256File(path string) (string, error) {
function installMySQL (line 304) | func installMySQL() error {
function runStart (line 387) | func runStart() error {
function startPostgreSQL (line 404) | func startPostgreSQL() error {
function configurePgHBA (line 508) | func configurePgHBA(hbaPath string) error {
function configurePgHBAWithMD5 (line 519) | func configurePgHBAWithMD5(hbaPath string) error {
function appendToFile (line 530) | func appendToFile(path, text string) error {
function pgIsReady (line 541) | func pgIsReady() bool {
function waitForPostgreSQL (line 547) | func waitForPostgreSQL(timeout time.Duration) error {
function startMySQL (line 558) | func startMySQL() error {
function ensureMySQLDirs (line 633) | func ensureMySQLDirs() error {
function startMySQLDaemon (line 645) | func startMySQLDaemon(extraArgs ...string) error {
function mysqlReady (line 664) | func mysqlReady() bool {
function waitForMySQL (line 670) | func waitForMySQL(timeout time.Duration) error {
function verifyMySQL (line 685) | func verifyMySQL() error {
function mysqlInitialized (line 697) | func mysqlInitialized() bool {
FILE: cmd/sqlc/main.go
function main (line 9) | func main() {
FILE: docs/conf.py
function setup (line 69) | def setup(app):
FILE: examples/authors/mysql/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/authors/mysql/db_test.go
function TestAuthors (line 15) | func TestAuthors(t *testing.T) {
FILE: examples/authors/mysql/models.go
type Author (line 11) | type Author struct
FILE: examples/authors/mysql/query.sql.go
constant createAuthor (line 13) | createAuthor = `-- name: CreateAuthor :execresult
type CreateAuthorParams (line 21) | type CreateAuthorParams struct
method CreateAuthor (line 26) | func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorPara...
constant deleteAuthor (line 30) | deleteAuthor = `-- name: DeleteAuthor :exec
method DeleteAuthor (line 35) | func (q *Queries) DeleteAuthor(ctx context.Context, id int64) error {
constant getAuthor (line 40) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 45) | func (q *Queries) GetAuthor(ctx context.Context, id int64) (Author, erro...
constant listAuthors (line 52) | listAuthors = `-- name: ListAuthors :many
method ListAuthors (line 57) | func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
FILE: examples/authors/mysql/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: examples/authors/postgresql/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: examples/authors/postgresql/db_test.go
function TestAuthors (line 15) | func TestAuthors(t *testing.T) {
FILE: examples/authors/postgresql/models.go
type Author (line 11) | type Author struct
FILE: examples/authors/postgresql/query.sql.go
constant createAuthor (line 14) | createAuthor = `-- name: CreateAuthor :one
type CreateAuthorParams (line 23) | type CreateAuthorParams struct
method CreateAuthor (line 28) | func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorPara...
constant deleteAuthor (line 35) | deleteAuthor = `-- name: DeleteAuthor :exec
method DeleteAuthor (line 40) | func (q *Queries) DeleteAuthor(ctx context.Context, id int64) error {
constant getAuthor (line 45) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 50) | func (q *Queries) GetAuthor(ctx context.Context, id int64) (Author, erro...
constant listAuthors (line 57) | listAuthors = `-- name: ListAuthors :many
method ListAuthors (line 62) | func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
FILE: examples/authors/postgresql/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: examples/authors/sqlite/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/authors/sqlite/db_test.go
function TestAuthors (line 13) | func TestAuthors(t *testing.T) {
FILE: examples/authors/sqlite/models.go
type Author (line 11) | type Author struct
FILE: examples/authors/sqlite/query.sql.go
constant createAuthor (line 13) | createAuthor = `-- name: CreateAuthor :execresult
type CreateAuthorParams (line 21) | type CreateAuthorParams struct
method CreateAuthor (line 26) | func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorPara...
constant deleteAuthor (line 30) | deleteAuthor = `-- name: DeleteAuthor :exec
method DeleteAuthor (line 35) | func (q *Queries) DeleteAuthor(ctx context.Context, id int64) error {
constant getAuthor (line 40) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 45) | func (q *Queries) GetAuthor(ctx context.Context, id int64) (Author, erro...
constant listAuthors (line 52) | listAuthors = `-- name: ListAuthors :many
method ListAuthors (line 57) | func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
FILE: examples/authors/sqlite/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: examples/batch/postgresql/batch.go
constant booksByYear (line 20) | booksByYear = `-- name: BooksByYear :batchmany
type BooksByYearBatchResults (line 25) | type BooksByYearBatchResults struct
method Query (line 43) | func (b *BooksByYearBatchResults) Query(f func(int, []Book, error)) {
method Close (line 83) | func (b *BooksByYearBatchResults) Close() error {
method BooksByYear (line 31) | func (q *Queries) BooksByYear(ctx context.Context, year []int32) *BooksB...
constant createBook (line 88) | createBook = `-- name: CreateBook :batchone
type CreateBookBatchResults (line 109) | type CreateBookBatchResults struct
method QueryRow (line 143) | func (b *CreateBookBatchResults) QueryRow(f func(int, Book, error)) {
method Close (line 170) | func (b *CreateBookBatchResults) Close() error {
type CreateBookParams (line 115) | type CreateBookParams struct
method CreateBook (line 125) | func (q *Queries) CreateBook(ctx context.Context, arg []CreateBookParams...
constant deleteBook (line 175) | deleteBook = `-- name: DeleteBook :batchexec
type DeleteBookBatchResults (line 180) | type DeleteBookBatchResults struct
method Exec (line 198) | func (b *DeleteBookBatchResults) Exec(f func(int, error)) {
method Close (line 214) | func (b *DeleteBookBatchResults) Close() error {
method DeleteBook (line 186) | func (q *Queries) DeleteBook(ctx context.Context, bookID []int32) *Delet...
constant deleteBookNamedFunc (line 219) | deleteBookNamedFunc = `-- name: DeleteBookNamedFunc :batchexec
type DeleteBookNamedFuncBatchResults (line 224) | type DeleteBookNamedFuncBatchResults struct
method Exec (line 242) | func (b *DeleteBookNamedFuncBatchResults) Exec(f func(int, error)) {
method Close (line 258) | func (b *DeleteBookNamedFuncBatchResults) Close() error {
method DeleteBookNamedFunc (line 230) | func (q *Queries) DeleteBookNamedFunc(ctx context.Context, bookID []int3...
constant deleteBookNamedSign (line 263) | deleteBookNamedSign = `-- name: DeleteBookNamedSign :batchexec
type DeleteBookNamedSignBatchResults (line 268) | type DeleteBookNamedSignBatchResults struct
method Exec (line 286) | func (b *DeleteBookNamedSignBatchResults) Exec(f func(int, error)) {
method Close (line 302) | func (b *DeleteBookNamedSignBatchResults) Close() error {
method DeleteBookNamedSign (line 274) | func (q *Queries) DeleteBookNamedSign(ctx context.Context, bookID []int3...
constant getBiography (line 307) | getBiography = `-- name: GetBiography :batchone
type GetBiographyBatchResults (line 312) | type GetBiographyBatchResults struct
method QueryRow (line 330) | func (b *GetBiographyBatchResults) QueryRow(f func(int, []byte, error)) {
method Close (line 348) | func (b *GetBiographyBatchResults) Close() error {
method GetBiography (line 318) | func (q *Queries) GetBiography(ctx context.Context, authorID []int32) *G...
constant updateBook (line 353) | updateBook = `-- name: UpdateBook :batchexec
type UpdateBookBatchResults (line 359) | type UpdateBookBatchResults struct
method Exec (line 385) | func (b *UpdateBookBatchResults) Exec(f func(int, error)) {
method Close (line 401) | func (b *UpdateBookBatchResults) Close() error {
type UpdateBookParams (line 365) | type UpdateBookParams struct
method UpdateBook (line 371) | func (q *Queries) UpdateBook(ctx context.Context, arg []UpdateBookParams...
FILE: examples/batch/postgresql/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: examples/batch/postgresql/db_test.go
function TestBatchBooks (line 16) | func TestBatchBooks(t *testing.T) {
FILE: examples/batch/postgresql/models.go
type BookType (line 14) | type BookType
method Scan (line 21) | func (e *BookType) Scan(src interface{}) error {
constant BookTypeFICTION (line 17) | BookTypeFICTION BookType = "FICTION"
constant BookTypeNONFICTION (line 18) | BookTypeNONFICTION BookType = "NONFICTION"
type NullBookType (line 33) | type NullBookType struct
method Scan (line 39) | func (ns *NullBookType) Scan(value interface{}) error {
method Value (line 49) | func (ns NullBookType) Value() (driver.Value, error) {
type Author (line 56) | type Author struct
type Book (line 62) | type Book struct
FILE: examples/batch/postgresql/querier.go
type Querier (line 13) | type Querier interface
FILE: examples/batch/postgresql/query.sql.go
constant createAuthor (line 14) | createAuthor = `-- name: CreateAuthor :one
method CreateAuthor (line 19) | func (q *Queries) CreateAuthor(ctx context.Context, name string) (Author...
constant deleteBookExecResult (line 26) | deleteBookExecResult = `-- name: DeleteBookExecResult :execresult
method DeleteBookExecResult (line 31) | func (q *Queries) DeleteBookExecResult(ctx context.Context, bookID int32...
constant getAuthor (line 35) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 40) | func (q *Queries) GetAuthor(ctx context.Context, authorID int32) (Author...
FILE: examples/batch/postgresql/schema.sql
type authors (line 1) | CREATE TABLE authors (
type books (line 12) | CREATE TABLE books (
FILE: examples/booktest/mysql/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/booktest/mysql/db_test.go
function TestBooks (line 16) | func TestBooks(t *testing.T) {
FILE: examples/booktest/mysql/models.go
type BooksBookType (line 13) | type BooksBookType
method Scan (line 20) | func (e *BooksBookType) Scan(src interface{}) error {
constant BooksBookTypeFICTION (line 16) | BooksBookTypeFICTION BooksBookType = "FICTION"
constant BooksBookTypeNONFICTION (line 17) | BooksBookTypeNONFICTION BooksBookType = "NONFICTION"
type NullBooksBookType (line 32) | type NullBooksBookType struct
method Scan (line 38) | func (ns *NullBooksBookType) Scan(value interface{}) error {
method Value (line 48) | func (ns NullBooksBookType) Value() (driver.Value, error) {
type Author (line 55) | type Author struct
type Book (line 60) | type Book struct
FILE: examples/booktest/mysql/query.sql.go
constant booksByTags (line 14) | booksByTags = `-- name: BooksByTags :many
type BooksByTagsRow (line 26) | type BooksByTagsRow struct
method BooksByTags (line 34) | func (q *Queries) BooksByTags(ctx context.Context, tags string) ([]Books...
constant booksByTitleYear (line 63) | booksByTitleYear = `-- name: BooksByTitleYear :many
type BooksByTitleYearParams (line 68) | type BooksByTitleYearParams struct
method BooksByTitleYear (line 73) | func (q *Queries) BooksByTitleYear(ctx context.Context, arg BooksByTitle...
constant createAuthor (line 105) | createAuthor = `-- name: CreateAuthor :execresult
method CreateAuthor (line 109) | func (q *Queries) CreateAuthor(ctx context.Context, name string) (sql.Re...
constant createBook (line 113) | createBook = `-- name: CreateBook :execresult
type CreateBookParams (line 133) | type CreateBookParams struct
method CreateBook (line 143) | func (q *Queries) CreateBook(ctx context.Context, arg CreateBookParams) ...
constant deleteAuthorBeforeYear (line 155) | deleteAuthorBeforeYear = `-- name: DeleteAuthorBeforeYear :exec
type DeleteAuthorBeforeYearParams (line 160) | type DeleteAuthorBeforeYearParams struct
method DeleteAuthorBeforeYear (line 165) | func (q *Queries) DeleteAuthorBeforeYear(ctx context.Context, arg Delete...
constant deleteBook (line 170) | deleteBook = `-- name: DeleteBook :exec
method DeleteBook (line 175) | func (q *Queries) DeleteBook(ctx context.Context, bookID int32) error {
constant getAuthor (line 180) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 185) | func (q *Queries) GetAuthor(ctx context.Context, authorID int32) (Author...
constant getBook (line 192) | getBook = `-- name: GetBook :one
method GetBook (line 197) | func (q *Queries) GetBook(ctx context.Context, bookID int32) (Book, erro...
constant updateBook (line 213) | updateBook = `-- name: UpdateBook :exec
type UpdateBookParams (line 219) | type UpdateBookParams struct
method UpdateBook (line 225) | func (q *Queries) UpdateBook(ctx context.Context, arg UpdateBookParams) ...
constant updateBookISBN (line 230) | updateBookISBN = `-- name: UpdateBookISBN :exec
type UpdateBookISBNParams (line 236) | type UpdateBookISBNParams struct
method UpdateBookISBN (line 243) | func (q *Queries) UpdateBookISBN(ctx context.Context, arg UpdateBookISBN...
FILE: examples/booktest/mysql/schema.sql
type authors (line 1) | CREATE TABLE authors (
type authors_name_idx (line 6) | CREATE INDEX authors_name_idx ON authors(name(255))
type books (line 8) | CREATE TABLE books (
type books_title_idx (line 20) | CREATE INDEX books_title_idx ON books(title(255), yr)
FILE: examples/booktest/postgresql/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: examples/booktest/postgresql/db_test.go
function TestBooks (line 16) | func TestBooks(t *testing.T) {
FILE: examples/booktest/postgresql/models.go
type BookType (line 14) | type BookType
method Scan (line 21) | func (e *BookType) Scan(src interface{}) error {
constant BookTypeFICTION (line 17) | BookTypeFICTION BookType = "FICTION"
constant BookTypeNONFICTION (line 18) | BookTypeNONFICTION BookType = "NONFICTION"
type NullBookType (line 33) | type NullBookType struct
method Scan (line 39) | func (ns *NullBookType) Scan(value interface{}) error {
method Value (line 49) | func (ns NullBookType) Value() (driver.Value, error) {
type Author (line 56) | type Author struct
type Book (line 61) | type Book struct
FILE: examples/booktest/postgresql/query.sql.go
constant booksByTags (line 14) | booksByTags = `-- name: BooksByTags :many
type BooksByTagsRow (line 26) | type BooksByTagsRow struct
method BooksByTags (line 34) | func (q *Queries) BooksByTags(ctx context.Context, dollar_1 []string) ([...
constant booksByTitleYear (line 60) | booksByTitleYear = `-- name: BooksByTitleYear :many
type BooksByTitleYearParams (line 65) | type BooksByTitleYearParams struct
method BooksByTitleYear (line 70) | func (q *Queries) BooksByTitleYear(ctx context.Context, arg BooksByTitle...
constant createAuthor (line 99) | createAuthor = `-- name: CreateAuthor :one
method CreateAuthor (line 104) | func (q *Queries) CreateAuthor(ctx context.Context, name string) (Author...
constant createBook (line 111) | createBook = `-- name: CreateBook :one
type CreateBookParams (line 132) | type CreateBookParams struct
method CreateBook (line 142) | func (q *Queries) CreateBook(ctx context.Context, arg CreateBookParams) ...
constant deleteBook (line 166) | deleteBook = `-- name: DeleteBook :exec
method DeleteBook (line 171) | func (q *Queries) DeleteBook(ctx context.Context, bookID int32) error {
constant getAuthor (line 176) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 181) | func (q *Queries) GetAuthor(ctx context.Context, authorID int32) (Author...
constant getBook (line 188) | getBook = `-- name: GetBook :one
method GetBook (line 193) | func (q *Queries) GetBook(ctx context.Context, bookID int32) (Book, erro...
constant sayHello (line 209) | sayHello = `-- name: SayHello :one
method SayHello (line 213) | func (q *Queries) SayHello(ctx context.Context, s string) (pgtype.Text, ...
constant updateBook (line 220) | updateBook = `-- name: UpdateBook :exec
type UpdateBookParams (line 226) | type UpdateBookParams struct
method UpdateBook (line 232) | func (q *Queries) UpdateBook(ctx context.Context, arg UpdateBookParams) ...
constant updateBookISBN (line 237) | updateBookISBN = `-- name: UpdateBookISBN :exec
type UpdateBookISBNParams (line 243) | type UpdateBookISBNParams struct
method UpdateBookISBN (line 250) | func (q *Queries) UpdateBookISBN(ctx context.Context, arg UpdateBookISBN...
FILE: examples/booktest/postgresql/schema.sql
type authors (line 1) | CREATE TABLE authors (
type authors_name_idx (line 6) | CREATE INDEX authors_name_idx ON authors(name)
type books (line 13) | CREATE TABLE books (
type books_title_idx (line 24) | CREATE INDEX books_title_idx ON books(title, year)
function say_hello (line 26) | CREATE FUNCTION say_hello(s text) RETURNS text AS $$
type books_title_lower_idx (line 32) | CREATE INDEX books_title_lower_idx ON books(title)
FILE: examples/booktest/sqlite/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/booktest/sqlite/db_test.go
constant BooksBookTypeFICTION (line 15) | BooksBookTypeFICTION string = "FICTION"
constant BooksBookTypeNONFICTION (line 16) | BooksBookTypeNONFICTION string = "NONFICTION"
function TestBooks (line 19) | func TestBooks(t *testing.T) {
FILE: examples/booktest/sqlite/models.go
type Author (line 11) | type Author struct
type Book (line 16) | type Book struct
FILE: examples/booktest/sqlite/query.sql.go
constant booksByTags (line 15) | booksByTags = `-- name: BooksByTags :many
type BooksByTagsRow (line 27) | type BooksByTagsRow struct
method BooksByTags (line 35) | func (q *Queries) BooksByTags(ctx context.Context, tags []string) ([]Boo...
constant booksByTitleYear (line 74) | booksByTitleYear = `-- name: BooksByTitleYear :many
type BooksByTitleYearParams (line 79) | type BooksByTitleYearParams struct
method BooksByTitleYear (line 84) | func (q *Queries) BooksByTitleYear(ctx context.Context, arg BooksByTitle...
constant createAuthor (line 116) | createAuthor = `-- name: CreateAuthor :one
method CreateAuthor (line 121) | func (q *Queries) CreateAuthor(ctx context.Context, name string) (Author...
constant createBook (line 128) | createBook = `-- name: CreateBook :one
type CreateBookParams (line 149) | type CreateBookParams struct
method CreateBook (line 159) | func (q *Queries) CreateBook(ctx context.Context, arg CreateBookParams) ...
constant deleteAuthorBeforeYear (line 183) | deleteAuthorBeforeYear = `-- name: DeleteAuthorBeforeYear :exec
type DeleteAuthorBeforeYearParams (line 188) | type DeleteAuthorBeforeYearParams struct
method DeleteAuthorBeforeYear (line 193) | func (q *Queries) DeleteAuthorBeforeYear(ctx context.Context, arg Delete...
constant deleteBook (line 198) | deleteBook = `-- name: DeleteBook :exec
method DeleteBook (line 203) | func (q *Queries) DeleteBook(ctx context.Context, bookID int64) error {
constant getAuthor (line 208) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 213) | func (q *Queries) GetAuthor(ctx context.Context, authorID int64) (Author...
constant getBook (line 220) | getBook = `-- name: GetBook :one
method GetBook (line 225) | func (q *Queries) GetBook(ctx context.Context, bookID int64) (Book, erro...
constant updateBook (line 241) | updateBook = `-- name: UpdateBook :exec
type UpdateBookParams (line 247) | type UpdateBookParams struct
method UpdateBook (line 253) | func (q *Queries) UpdateBook(ctx context.Context, arg UpdateBookParams) ...
constant updateBookISBN (line 258) | updateBookISBN = `-- name: UpdateBookISBN :exec
type UpdateBookISBNParams (line 264) | type UpdateBookISBNParams struct
method UpdateBookISBN (line 271) | func (q *Queries) UpdateBookISBN(ctx context.Context, arg UpdateBookISBN...
FILE: examples/booktest/sqlite/schema.sql
type authors (line 1) | CREATE TABLE authors (
type authors_name_idx (line 6) | CREATE INDEX authors_name_idx ON authors(name)
type books (line 8) | CREATE TABLE books (
type books_title_idx (line 20) | CREATE INDEX books_title_idx ON books(title, yr)
FILE: examples/jets/postgresql/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: examples/jets/postgresql/models.go
type Jet (line 7) | type Jet struct
type Language (line 15) | type Language struct
type Pilot (line 20) | type Pilot struct
type PilotLanguage (line 25) | type PilotLanguage struct
FILE: examples/jets/postgresql/query-building.sql.go
constant countPilots (line 12) | countPilots = `-- name: CountPilots :one
method CountPilots (line 16) | func (q *Queries) CountPilots(ctx context.Context) (int64, error) {
constant deletePilot (line 23) | deletePilot = `-- name: DeletePilot :exec
method DeletePilot (line 27) | func (q *Queries) DeletePilot(ctx context.Context, id int32) error {
constant listPilots (line 32) | listPilots = `-- name: ListPilots :many
method ListPilots (line 36) | func (q *Queries) ListPilots(ctx context.Context) ([]Pilot, error) {
FILE: examples/jets/postgresql/schema.sql
type pilots (line 1) | CREATE TABLE pilots (
type jets (line 8) | CREATE TABLE jets (
type languages (line 19) | CREATE TABLE languages (
type pilot_languages (line 27) | CREATE TABLE pilot_languages (
FILE: examples/ondeck/mysql/city.sql.go
constant createCity (line 12) | createCity = `-- name: CreateCity :exec
type CreateCityParams (line 22) | type CreateCityParams struct
method CreateCity (line 27) | func (q *Queries) CreateCity(ctx context.Context, arg CreateCityParams) ...
constant getCity (line 32) | getCity = `-- name: GetCity :one
method GetCity (line 38) | func (q *Queries) GetCity(ctx context.Context, slug string) (City, error) {
constant listCities (line 45) | listCities = `-- name: ListCities :many
method ListCities (line 51) | func (q *Queries) ListCities(ctx context.Context) ([]City, error) {
constant updateCityName (line 74) | updateCityName = `-- name: UpdateCityName :exec
type UpdateCityNameParams (line 80) | type UpdateCityNameParams struct
method UpdateCityName (line 85) | func (q *Queries) UpdateCityName(ctx context.Context, arg UpdateCityName...
FILE: examples/ondeck/mysql/db.go
type DBTX (line 13) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
function Prepare (line 24) | func Prepare(ctx context.Context, db DBTX) (*Queries, error) {
type Queries (line 148) | type Queries struct
method Close (line 60) | func (q *Queries) Close() error {
method exec (line 115) | func (q *Queries) exec(ctx context.Context, stmt *sql.Stmt, query stri...
method query (line 126) | func (q *Queries) query(ctx context.Context, stmt *sql.Stmt, query str...
method queryRow (line 137) | func (q *Queries) queryRow(ctx context.Context, stmt *sql.Stmt, query ...
method WithTx (line 163) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/ondeck/mysql/db_test.go
function join (line 17) | func join(vals ...string) sql.NullString {
function runOnDeckQueries (line 27) | func runOnDeckQueries(t *testing.T, q *Queries) {
function TestPrepared (line 143) | func TestPrepared(t *testing.T) {
function TestQueries (line 161) | func TestQueries(t *testing.T) {
FILE: examples/ondeck/mysql/models.go
type VenueStatus (line 14) | type VenueStatus
method Scan (line 21) | func (e *VenueStatus) Scan(src interface{}) error {
constant VenueStatusOpen (line 17) | VenueStatusOpen VenueStatus = "open"
constant VenueStatusClosed (line 18) | VenueStatusClosed VenueStatus = "closed"
type NullVenueStatus (line 33) | type NullVenueStatus struct
method Scan (line 39) | func (ns *NullVenueStatus) Scan(value interface{}) error {
method Value (line 49) | func (ns NullVenueStatus) Value() (driver.Value, error) {
type City (line 56) | type City struct
type Venue (line 62) | type Venue struct
FILE: examples/ondeck/mysql/querier.go
type Querier (line 12) | type Querier interface
FILE: examples/ondeck/mysql/schema/0001_city.sql
type city (line 1) | CREATE TABLE city (
FILE: examples/ondeck/mysql/schema/0002_venue.sql
type venues (line 1) | CREATE TABLE venues (
FILE: examples/ondeck/mysql/venue.sql.go
constant createVenue (line 13) | createVenue = `-- name: CreateVenue :execresult
type CreateVenueParams (line 35) | type CreateVenueParams struct
method CreateVenue (line 45) | func (q *Queries) CreateVenue(ctx context.Context, arg CreateVenueParams...
constant deleteVenue (line 57) | deleteVenue = `-- name: DeleteVenue :exec
type DeleteVenueParams (line 62) | type DeleteVenueParams struct
method DeleteVenue (line 67) | func (q *Queries) DeleteVenue(ctx context.Context, arg DeleteVenueParams...
constant getVenue (line 72) | getVenue = `-- name: GetVenue :one
type GetVenueParams (line 78) | type GetVenueParams struct
method GetVenue (line 83) | func (q *Queries) GetVenue(ctx context.Context, arg GetVenueParams) (Ven...
constant listVenues (line 101) | listVenues = `-- name: ListVenues :many
method ListVenues (line 108) | func (q *Queries) ListVenues(ctx context.Context, city string) ([]Venue,...
constant updateVenueName (line 142) | updateVenueName = `-- name: UpdateVenueName :exec
type UpdateVenueNameParams (line 148) | type UpdateVenueNameParams struct
method UpdateVenueName (line 153) | func (q *Queries) UpdateVenueName(ctx context.Context, arg UpdateVenueNa...
constant venueCountByCity (line 158) | venueCountByCity = `-- name: VenueCountByCity :many
type VenueCountByCityRow (line 167) | type VenueCountByCityRow struct
method VenueCountByCity (line 172) | func (q *Queries) VenueCountByCity(ctx context.Context) ([]VenueCountByC...
FILE: examples/ondeck/postgresql/city.sql.go
constant createCity (line 12) | createCity = `-- name: CreateCity :one
type CreateCityParams (line 22) | type CreateCityParams struct
method CreateCity (line 30) | func (q *Queries) CreateCity(ctx context.Context, arg CreateCityParams) ...
constant getCity (line 37) | getCity = `-- name: GetCity :one
method GetCity (line 43) | func (q *Queries) GetCity(ctx context.Context, slug string) (City, error) {
constant listCities (line 50) | listCities = `-- name: ListCities :many
method ListCities (line 56) | func (q *Queries) ListCities(ctx context.Context) ([]City, error) {
constant updateCityName (line 79) | updateCityName = `-- name: UpdateCityName :exec
type UpdateCityNameParams (line 85) | type UpdateCityNameParams struct
method UpdateCityName (line 90) | func (q *Queries) UpdateCityName(ctx context.Context, arg UpdateCityName...
FILE: examples/ondeck/postgresql/db.go
type DBTX (line 13) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
function Prepare (line 24) | func Prepare(ctx context.Context, db DBTX) (*Queries, error) {
type Queries (line 148) | type Queries struct
method Close (line 60) | func (q *Queries) Close() error {
method exec (line 115) | func (q *Queries) exec(ctx context.Context, stmt *sql.Stmt, query stri...
method query (line 126) | func (q *Queries) query(ctx context.Context, stmt *sql.Stmt, query str...
method queryRow (line 137) | func (q *Queries) queryRow(ctx context.Context, stmt *sql.Stmt, query ...
method WithTx (line 163) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/ondeck/postgresql/db_test.go
function runOnDeckQueries (line 16) | func runOnDeckQueries(t *testing.T, q *Queries) {
function TestPrepared (line 125) | func TestPrepared(t *testing.T) {
function TestQueries (line 143) | func TestQueries(t *testing.T) {
FILE: examples/ondeck/postgresql/models.go
type Status (line 15) | type Status
method Scan (line 22) | func (e *Status) Scan(src interface{}) error {
constant StatusOpen (line 18) | StatusOpen Status = "op!en"
constant StatusClosed (line 19) | StatusClosed Status = "clo@sed"
type NullStatus (line 34) | type NullStatus struct
method Scan (line 40) | func (ns *NullStatus) Scan(value interface{}) error {
method Value (line 50) | func (ns NullStatus) Value() (driver.Value, error) {
type City (line 57) | type City struct
type Venue (line 63) | type Venue struct
FILE: examples/ondeck/postgresql/querier.go
type Querier (line 11) | type Querier interface
FILE: examples/ondeck/postgresql/schema/0001_city.sql
type city (line 1) | CREATE TABLE city (
FILE: examples/ondeck/postgresql/schema/0002_venue.sql
type venues (line 4) | CREATE TABLE venues (
FILE: examples/ondeck/postgresql/venue.sql.go
constant createVenue (line 14) | createVenue = `-- name: CreateVenue :one
type CreateVenueParams (line 36) | type CreateVenueParams struct
method CreateVenue (line 46) | func (q *Queries) CreateVenue(ctx context.Context, arg CreateVenueParams...
constant deleteVenue (line 61) | deleteVenue = `-- name: DeleteVenue :exec
method DeleteVenue (line 66) | func (q *Queries) DeleteVenue(ctx context.Context, slug string) error {
constant getVenue (line 71) | getVenue = `-- name: GetVenue :one
type GetVenueParams (line 77) | type GetVenueParams struct
method GetVenue (line 82) | func (q *Queries) GetVenue(ctx context.Context, arg GetVenueParams) (Ven...
constant listVenues (line 100) | listVenues = `-- name: ListVenues :many
method ListVenues (line 107) | func (q *Queries) ListVenues(ctx context.Context, city string) ([]Venue,...
constant updateVenueName (line 141) | updateVenueName = `-- name: UpdateVenueName :one
type UpdateVenueNameParams (line 148) | type UpdateVenueNameParams struct
method UpdateVenueName (line 153) | func (q *Queries) UpdateVenueName(ctx context.Context, arg UpdateVenueNa...
constant venueCountByCity (line 160) | venueCountByCity = `-- name: VenueCountByCity :many
type VenueCountByCityRow (line 169) | type VenueCountByCityRow struct
method VenueCountByCity (line 174) | func (q *Queries) VenueCountByCity(ctx context.Context) ([]VenueCountByC...
FILE: examples/ondeck/sqlite/city.sql.go
constant createCity (line 12) | createCity = `-- name: CreateCity :exec
type CreateCityParams (line 22) | type CreateCityParams struct
method CreateCity (line 27) | func (q *Queries) CreateCity(ctx context.Context, arg CreateCityParams) ...
constant getCity (line 32) | getCity = `-- name: GetCity :one
method GetCity (line 38) | func (q *Queries) GetCity(ctx context.Context, slug string) (City, error) {
constant listCities (line 45) | listCities = `-- name: ListCities :many
method ListCities (line 51) | func (q *Queries) ListCities(ctx context.Context) ([]City, error) {
constant updateCityName (line 74) | updateCityName = `-- name: UpdateCityName :exec
type UpdateCityNameParams (line 80) | type UpdateCityNameParams struct
method UpdateCityName (line 85) | func (q *Queries) UpdateCityName(ctx context.Context, arg UpdateCityName...
FILE: examples/ondeck/sqlite/db.go
type DBTX (line 13) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
function Prepare (line 24) | func Prepare(ctx context.Context, db DBTX) (*Queries, error) {
type Queries (line 148) | type Queries struct
method Close (line 60) | func (q *Queries) Close() error {
method exec (line 115) | func (q *Queries) exec(ctx context.Context, stmt *sql.Stmt, query stri...
method query (line 126) | func (q *Queries) query(ctx context.Context, stmt *sql.Stmt, query str...
method queryRow (line 137) | func (q *Queries) queryRow(ctx context.Context, stmt *sql.Stmt, query ...
method WithTx (line 163) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: examples/ondeck/sqlite/db_test.go
constant VenuesStatusOpen (line 18) | VenuesStatusOpen string = "open"
constant VenuesStatusClosed (line 19) | VenuesStatusClosed string = "closed"
function join (line 22) | func join(vals ...string) sql.NullString {
function runOnDeckQueries (line 32) | func runOnDeckQueries(t *testing.T, q *Queries) {
function TestPrepared (line 148) | func TestPrepared(t *testing.T) {
function TestQueries (line 163) | func TestQueries(t *testing.T) {
FILE: examples/ondeck/sqlite/models.go
type City (line 12) | type City struct
type Venue (line 17) | type Venue struct
FILE: examples/ondeck/sqlite/querier.go
type Querier (line 12) | type Querier interface
FILE: examples/ondeck/sqlite/schema/0001_city.sql
type city (line 1) | CREATE TABLE city (
FILE: examples/ondeck/sqlite/schema/0002_venue.sql
type venues (line 1) | CREATE TABLE venues (
FILE: examples/ondeck/sqlite/venue.sql.go
constant createVenue (line 13) | createVenue = `-- name: CreateVenue :execresult
type CreateVenueParams (line 35) | type CreateVenueParams struct
method CreateVenue (line 45) | func (q *Queries) CreateVenue(ctx context.Context, arg CreateVenueParams...
constant deleteVenue (line 57) | deleteVenue = `-- name: DeleteVenue :exec
type DeleteVenueParams (line 62) | type DeleteVenueParams struct
method DeleteVenue (line 67) | func (q *Queries) DeleteVenue(ctx context.Context, arg DeleteVenueParams...
constant getVenue (line 72) | getVenue = `-- name: GetVenue :one
type GetVenueParams (line 78) | type GetVenueParams struct
method GetVenue (line 83) | func (q *Queries) GetVenue(ctx context.Context, arg GetVenueParams) (Ven...
constant listVenues (line 101) | listVenues = `-- name: ListVenues :many
method ListVenues (line 108) | func (q *Queries) ListVenues(ctx context.Context, city string) ([]Venue,...
constant updateVenueName (line 142) | updateVenueName = `-- name: UpdateVenueName :exec
type UpdateVenueNameParams (line 148) | type UpdateVenueNameParams struct
method UpdateVenueName (line 153) | func (q *Queries) UpdateVenueName(ctx context.Context, arg UpdateVenueNa...
constant venueCountByCity (line 158) | venueCountByCity = `-- name: VenueCountByCity :many
type VenueCountByCityRow (line 167) | type VenueCountByCityRow struct
method VenueCountByCity (line 172) | func (q *Queries) VenueCountByCity(ctx context.Context) ([]VenueCountByC...
FILE: internal/analysis/analysis.pb.go
constant _ (line 18) | _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
constant _ (line 20) | _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
type Identifier (line 23) | type Identifier struct
method Reset (line 33) | func (x *Identifier) Reset() {
method String (line 42) | func (x *Identifier) String() string {
method ProtoMessage (line 46) | func (*Identifier) ProtoMessage() {}
method ProtoReflect (line 48) | func (x *Identifier) ProtoReflect() protoreflect.Message {
method Descriptor (line 61) | func (*Identifier) Descriptor() ([]byte, []int) {
method GetCatalog (line 65) | func (x *Identifier) GetCatalog() string {
method GetSchema (line 72) | func (x *Identifier) GetSchema() string {
method GetName (line 79) | func (x *Identifier) GetName() string {
type Column (line 86) | type Column struct
method Reset (line 110) | func (x *Column) Reset() {
method String (line 119) | func (x *Column) String() string {
method ProtoMessage (line 123) | func (*Column) ProtoMessage() {}
method ProtoReflect (line 125) | func (x *Column) ProtoReflect() protoreflect.Message {
method Descriptor (line 138) | func (*Column) Descriptor() ([]byte, []int) {
method GetName (line 142) | func (x *Column) GetName() string {
method GetOriginalName (line 149) | func (x *Column) GetOriginalName() string {
method GetDataType (line 156) | func (x *Column) GetDataType() string {
method GetNotNull (line 163) | func (x *Column) GetNotNull() bool {
method GetUnsigned (line 170) | func (x *Column) GetUnsigned() bool {
method GetIsArray (line 177) | func (x *Column) GetIsArray() bool {
method GetArrayDims (line 184) | func (x *Column) GetArrayDims() int32 {
method GetComment (line 191) | func (x *Column) GetComment() string {
method GetLength (line 198) | func (x *Column) GetLength() int32 {
method GetIsNamedParam (line 205) | func (x *Column) GetIsNamedParam() bool {
method GetIsFuncCall (line 212) | func (x *Column) GetIsFuncCall() bool {
method GetScope (line 219) | func (x *Column) GetScope() string {
method GetTable (line 226) | func (x *Column) GetTable() *Identifier {
method GetTableAlias (line 233) | func (x *Column) GetTableAlias() string {
method GetType (line 240) | func (x *Column) GetType() *Identifier {
method GetEmbedTable (line 247) | func (x *Column) GetEmbedTable() *Identifier {
method GetIsSqlcSlice (line 254) | func (x *Column) GetIsSqlcSlice() bool {
type Parameter (line 261) | type Parameter struct
method Reset (line 270) | func (x *Parameter) Reset() {
method String (line 279) | func (x *Parameter) String() string {
method ProtoMessage (line 283) | func (*Parameter) ProtoMessage() {}
method ProtoReflect (line 285) | func (x *Parameter) ProtoReflect() protoreflect.Message {
method Descriptor (line 298) | func (*Parameter) Descriptor() ([]byte, []int) {
method GetNumber (line 302) | func (x *Parameter) GetNumber() int32 {
method GetColumn (line 309) | func (x *Parameter) GetColumn() *Column {
type Analysis (line 316) | type Analysis struct
method Reset (line 325) | func (x *Analysis) Reset() {
method String (line 334) | func (x *Analysis) String() string {
method ProtoMessage (line 338) | func (*Analysis) ProtoMessage() {}
method ProtoReflect (line 340) | func (x *Analysis) ProtoReflect() protoreflect.Message {
method Descriptor (line 353) | func (*Analysis) Descriptor() ([]byte, []int) {
method GetColumns (line 357) | func (x *Analysis) GetColumns() []*Column {
method GetParams (line 364) | func (x *Analysis) GetParams() []*Parameter {
function file_analysis_analysis_proto_rawDescGZIP (line 445) | func file_analysis_analysis_proto_rawDescGZIP() []byte {
function init (line 473) | func init() { file_analysis_analysis_proto_init() }
function file_analysis_analysis_proto_init (line 474) | func file_analysis_analysis_proto_init() {
FILE: internal/analysis/analysis_vtproto.pb.go
constant _ (line 17) | _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
constant _ (line 19) | _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
method CloneVT (line 22) | func (m *Identifier) CloneVT() *Identifier {
method CloneMessageVT (line 38) | func (m *Identifier) CloneMessageVT() proto.Message {
method CloneVT (line 42) | func (m *Column) CloneVT() *Column {
method CloneMessageVT (line 72) | func (m *Column) CloneMessageVT() proto.Message {
method CloneVT (line 76) | func (m *Parameter) CloneVT() *Parameter {
method CloneMessageVT (line 91) | func (m *Parameter) CloneMessageVT() proto.Message {
method CloneVT (line 95) | func (m *Analysis) CloneVT() *Analysis {
method CloneMessageVT (line 121) | func (m *Analysis) CloneMessageVT() proto.Message {
method EqualVT (line 125) | func (this *Identifier) EqualVT(that *Identifier) bool {
method EqualMessageVT (line 143) | func (this *Identifier) EqualMessageVT(thatMsg proto.Message) bool {
method EqualVT (line 150) | func (this *Column) EqualVT(that *Column) bool {
method EqualMessageVT (line 210) | func (this *Column) EqualMessageVT(thatMsg proto.Message) bool {
method EqualVT (line 217) | func (this *Parameter) EqualVT(that *Parameter) bool {
method EqualMessageVT (line 232) | func (this *Parameter) EqualMessageVT(thatMsg proto.Message) bool {
method EqualVT (line 239) | func (this *Analysis) EqualVT(that *Analysis) bool {
method EqualMessageVT (line 282) | func (this *Analysis) EqualMessageVT(thatMsg proto.Message) bool {
method MarshalVT (line 289) | func (m *Identifier) MarshalVT() (dAtA []byte, err error) {
method MarshalToVT (line 302) | func (m *Identifier) MarshalToVT(dAtA []byte) (int, error) {
method MarshalToSizedBufferVT (line 307) | func (m *Identifier) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
method MarshalVT (line 343) | func (m *Column) MarshalVT() (dAtA []byte, err error) {
method MarshalToVT (line 356) | func (m *Column) MarshalToVT(dAtA []byte) (int, error) {
method MarshalToSizedBufferVT (line 361) | func (m *Column) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
method MarshalVT (line 522) | func (m *Parameter) MarshalVT() (dAtA []byte, err error) {
method MarshalToVT (line 535) | func (m *Parameter) MarshalToVT(dAtA []byte) (int, error) {
method MarshalToSizedBufferVT (line 540) | func (m *Parameter) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
method MarshalVT (line 570) | func (m *Analysis) MarshalVT() (dAtA []byte, err error) {
method MarshalToVT (line 583) | func (m *Analysis) MarshalToVT(dAtA []byte) (int, error) {
method MarshalToSizedBufferVT (line 588) | func (m *Analysis) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
function encodeVarint (line 627) | func encodeVarint(dAtA []byte, offset int, v uint64) int {
method MarshalVTStrict (line 638) | func (m *Identifier) MarshalVTStrict() (dAtA []byte, err error) {
method MarshalToVTStrict (line 651) | func (m *Identifier) MarshalToVTStrict(dAtA []byte) (int, error) {
method MarshalToSizedBufferVTStrict (line 656) | func (m *Identifier) MarshalToSizedBufferVTStrict(dAtA []byte) (int, err...
method MarshalVTStrict (line 692) | func (m *Column) MarshalVTStrict() (dAtA []byte, err error) {
method MarshalToVTStrict (line 705) | func (m *Column) MarshalToVTStrict(dAtA []byte) (int, error) {
method MarshalToSizedBufferVTStrict (line 710) | func (m *Column) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
method MarshalVTStrict (line 871) | func (m *Parameter) MarshalVTStrict() (dAtA []byte, err error) {
method MarshalToVTStrict (line 884) | func (m *Parameter) MarshalToVTStrict(dAtA []byte) (int, error) {
method MarshalToSizedBufferVTStrict (line 889) | func (m *Parameter) MarshalToSizedBufferVTStrict(dAtA []byte) (int, erro...
method MarshalVTStrict (line 919) | func (m *Analysis) MarshalVTStrict() (dAtA []byte, err error) {
method MarshalToVTStrict (line 932) | func (m *Analysis) MarshalToVTStrict(dAtA []byte) (int, error) {
method MarshalToSizedBufferVTStrict (line 937) | func (m *Analysis) MarshalToSizedBufferVTStrict(dAtA []byte) (int, error) {
method SizeVT (line 976) | func (m *Identifier) SizeVT() (n int) {
method SizeVT (line 998) | func (m *Column) SizeVT() (n int) {
method SizeVT (line 1068) | func (m *Parameter) SizeVT() (n int) {
method SizeVT (line 1085) | func (m *Analysis) SizeVT() (n int) {
function sov (line 1107) | func sov(x uint64) (n int) {
function soz (line 1110) | func soz(x uint64) (n int) {
method UnmarshalVT (line 1113) | func (m *Identifier) UnmarshalVT(dAtA []byte) error {
method UnmarshalVT (line 1260) | func (m *Column) UnmarshalVT(dAtA []byte) error {
method UnmarshalVT (line 1769) | func (m *Parameter) UnmarshalVT(dAtA []byte) error {
method UnmarshalVT (line 1875) | func (m *Analysis) UnmarshalVT(dAtA []byte) error {
function skip (line 1995) | func skip(dAtA []byte) (n int, err error) {
FILE: internal/analyzer/analyzer.go
type CachedAnalyzer (line 22) | type CachedAnalyzer struct
method Analyze (line 39) | func (c *CachedAnalyzer) Analyze(ctx context.Context, n ast.Node, q st...
method analyze (line 50) | func (c *CachedAnalyzer) analyze(ctx context.Context, n ast.Node, q st...
method Close (line 109) | func (c *CachedAnalyzer) Close(ctx context.Context) error {
method EnsureConn (line 113) | func (c *CachedAnalyzer) EnsureConn(ctx context.Context, migrations []...
method GetColumnNames (line 117) | func (c *CachedAnalyzer) GetColumnNames(ctx context.Context, query str...
function Cached (line 29) | func Cached(a Analyzer, c config.Config, db config.Database) *CachedAnal...
type Analyzer (line 121) | type Analyzer interface
FILE: internal/bundler/multipart.go
function readFiles (line 11) | func readFiles(dir string, paths []string) ([]*pb.File, error) {
function readFile (line 27) | func readFile(dir string, path string) (*pb.File, error) {
FILE: internal/bundler/upload.go
type Uploader (line 33) | type Uploader struct
method Validate (line 55) | func (up *Uploader) Validate() error {
method buildRequest (line 130) | func (up *Uploader) buildRequest(ctx context.Context, results []*Query...
method DumpRequestOut (line 134) | func (up *Uploader) DumpRequestOut(ctx context.Context, result []*Quer...
method Upload (line 152) | func (up *Uploader) Upload(ctx context.Context, result []*QuerySetArch...
type QuerySetArchive (line 40) | type QuerySetArchive struct
function NewUploader (line 47) | func NewUploader(configPath, dir string, conf *config.Config) *Uploader {
function annotate (line 80) | func annotate() map[string]string {
function BuildRequest (line 89) | func BuildRequest(ctx context.Context, dir, configPath string, results [...
FILE: internal/cache/cache.go
function Dir (line 13) | func Dir() (string, error) {
function PluginsDir (line 25) | func PluginsDir() (string, error) {
function AnalysisDir (line 37) | func AnalysisDir() (string, error) {
FILE: internal/cmd/cmd.go
function init (line 27) | func init() {
function Do (line 37) | func Do(args []string, stdin io.Reader, stdout io.Writer, stderr io.Writ...
type Env (line 140) | type Env struct
method Validate (line 163) | func (e *Env) Validate(cfg *config.Config) error {
function ParseEnv (line 148) | func ParseEnv(c *cobra.Command) Env {
function getConfigPath (line 172) | func getConfigPath(stderr io.Writer, f *pflag.Flag) (string, string) {
function getLines (line 239) | func getLines(f []byte) []string {
function filterHunks (line 249) | func filterHunks[T gonp.Elem](uniHunks []gonp.UniHunk[T]) []gonp.UniHunk...
FILE: internal/cmd/createdb.go
function CreateDB (line 41) | func CreateDB(ctx context.Context, dir, filename, querySetName string, o...
FILE: internal/cmd/diff.go
function Diff (line 15) | func Diff(ctx context.Context, dir, name string, opts *Options) error {
FILE: internal/cmd/generate.go
constant errMessageNoVersion (line 35) | errMessageNoVersion = `The configuration file must have a version number.
constant errMessageUnknownVersion (line 44) | errMessageUnknownVersion = `The configuration file has an invalid versio...
constant errMessageNoPackages (line 48) | errMessageNoPackages = `No packages are configured`
function printFileErr (line 50) | func printFileErr(stderr io.Writer, dir string, fileErr *multierr.FileEr...
function findPlugin (line 58) | func findPlugin(conf config.Config, name string) (*config.Plugin, error) {
function readConfig (line 67) | func readConfig(stderr io.Writer, dir, filename string) (string, *config...
function Generate (line 134) | func Generate(ctx context.Context, dir, filename string, o *Options) (ma...
type generator (line 171) | type generator struct
method Pairs (line 177) | func (g *generator) Pairs(ctx context.Context, conf *config.Config) []...
method ProcessResult (line 202) | func (g *generator) ProcessResult(ctx context.Context, combo config.Co...
function remoteGenerate (line 233) | func remoteGenerate(ctx context.Context, configPath string, conf *config...
function parse (line 296) | func parse(ctx context.Context, name, dir string, sql config.SQL, combo ...
function codegen (line 336) | func codegen(ctx context.Context, combo config.CombinedSettings, sql Out...
FILE: internal/cmd/options.go
type Options (line 9) | type Options struct
method ReadConfig (line 20) | func (o *Options) ReadConfig(dir, filename string) (string, *config.Co...
FILE: internal/cmd/process.go
type OutputPair (line 20) | type OutputPair struct
type ResultProcessor (line 27) | type ResultProcessor interface
function Process (line 32) | func Process(ctx context.Context, rp ResultProcessor, dir, filename stri...
function processQuerySets (line 55) | func processQuerySets(ctx context.Context, rp ResultProcessor, conf *con...
FILE: internal/cmd/push.go
function init (line 16) | func init() {
type pusher (line 44) | type pusher struct
method Pairs (line 49) | func (g *pusher) Pairs(ctx context.Context, conf *config.Config) []Out...
method ProcessResult (line 59) | func (g *pusher) ProcessResult(ctx context.Context, combo config.Combi...
function Push (line 72) | func Push(ctx context.Context, dir, filename string, opts *Options) error {
FILE: internal/cmd/shim.go
function pluginSettings (line 12) | func pluginSettings(r *compiler.Result, cs config.CombinedSettings) *plu...
function pluginCodegen (line 22) | func pluginCodegen(cs config.CombinedSettings, s config.Codegen) *plugin...
function pluginProcess (line 43) | func pluginProcess(p config.Plugin) *plugin.Codegen_Process {
function pluginWASM (line 52) | func pluginWASM(p config.Plugin) *plugin.Codegen_WASM {
function pluginCatalog (line 62) | func pluginCatalog(c *catalog.Catalog) *plugin.Catalog {
function pluginQueries (line 136) | func pluginQueries(r *compiler.Result) []*plugin.Query {
function pluginQueryColumn (line 169) | func pluginQueryColumn(c *compiler.Column) *plugin.Column {
function pluginQueryParam (line 219) | func pluginQueryParam(p compiler.Parameter) *plugin.Parameter {
function codeGenRequest (line 226) | func codeGenRequest(r *compiler.Result, settings config.CombinedSettings...
FILE: internal/cmd/verify.go
function init (line 24) | func init() {
function Verify (line 51) | func Verify(ctx context.Context, dir, filename string, opts *Options) er...
FILE: internal/cmd/vet.go
function NewCmdVet (line 43) | func NewCmdVet() *cobra.Command {
function Vet (line 66) | func Vet(ctx context.Context, dir, filename string, opts *Options) error {
type preparer (line 169) | type preparer interface
type pgxConn (line 173) | type pgxConn struct
method Prepare (line 177) | func (p *pgxConn) Prepare(ctx context.Context, name, query string) err...
method Explain (line 308) | func (p *pgxConn) Explain(ctx context.Context, query string, args ...*...
function pgDefaultValue (line 184) | func pgDefaultValue(col *plugin.Column) any {
function mysqlDefaultValue (line 268) | func mysqlDefaultValue(col *plugin.Column) any {
type dbPreparer (line 330) | type dbPreparer struct
method Prepare (line 334) | func (p *dbPreparer) Prepare(ctx context.Context, name, query string) ...
type explainer (line 342) | type explainer interface
type mysqlExplainer (line 346) | type mysqlExplainer struct
method Explain (line 350) | func (me *mysqlExplainer) Explain(ctx context.Context, query string, a...
type rule (line 375) | type rule struct
type checker (line 382) | type checker struct
method fetchDatabaseUri (line 407) | func (c *checker) fetchDatabaseUri(ctx context.Context, s config.SQL) ...
method DSN (line 461) | func (c *checker) DSN(dsn string) (string, error) {
method checkSQL (line 465) | func (c *checker) checkSQL(ctx context.Context, s config.SQL) error {
function isInMemorySQLite (line 395) | func isInMemorySQLite(uri string) bool {
function vetConfig (line 677) | func vetConfig(req *plugin.GenerateRequest) *vet.Config {
function vetQuery (line 686) | func vetQuery(q *plugin.Query) *vet.Query {
type vetEngineOutput (line 701) | type vetEngineOutput struct
FILE: internal/codegen/golang/driver.go
function parseDriver (line 5) | func parseDriver(sqlPackage string) opts.SQLDriver {
FILE: internal/codegen/golang/enum.go
type Constant (line 8) | type Constant struct
type Enum (line 14) | type Enum struct
method NameTag (line 22) | func (e Enum) NameTag() string {
method ValidTag (line 26) | func (e Enum) ValidTag() string {
function enumReplacer (line 30) | func enumReplacer(r rune) rune {
function EnumReplace (line 44) | func EnumReplace(value string) string {
function EnumValueName (line 50) | func EnumValueName(value string) string {
function titleFirst (line 59) | func titleFirst(s string) string {
FILE: internal/codegen/golang/field.go
type Field (line 13) | type Field struct
method Tag (line 24) | func (gf Field) Tag() string {
method HasSqlcSlice (line 28) | func (gf Field) HasSqlcSlice() bool {
function TagsToString (line 32) | func TagsToString(tags map[string]string) string {
function JSONTagName (line 44) | func JSONTagName(name string, options *opts.Options) string {
function SetCaseStyle (line 54) | func SetCaseStyle(name string, style string) string {
function SetJSONCaseStyle (line 67) | func SetJSONCaseStyle(name string, style string, idUppercase bool) string {
function toSnakeCase (line 82) | func toSnakeCase(s string) string {
function toCamelCase (line 91) | func toCamelCase(s string) string {
function toPascalCase (line 95) | func toPascalCase(s string) string {
function toCamelInitCase (line 99) | func toCamelInitCase(name string, initUpper bool) string {
function toJsonCamelCase (line 115) | func toJsonCamelCase(name string, idUppercase bool) string {
function toLowerCase (line 137) | func toLowerCase(str string) string {
FILE: internal/codegen/golang/gen.go
type tmplCtx (line 19) | type tmplCtx struct
method OutputQuery (line 47) | func (t *tmplCtx) OutputQuery(sourceName string) bool {
method codegenDbarg (line 51) | func (t *tmplCtx) codegenDbarg() string {
method codegenEmitPreparedQueries (line 60) | func (t *tmplCtx) codegenEmitPreparedQueries() bool {
method codegenQueryMethod (line 64) | func (t *tmplCtx) codegenQueryMethod(q Query) string {
method codegenQueryRetval (line 91) | func (t *tmplCtx) codegenQueryRetval(q Query) (string, error) {
function Generate (line 111) | func Generate(ctx context.Context, req *plugin.GenerateRequest) (*plugin...
function validate (line 139) | func validate(options *opts.Options, enums []Enum, structs []Struct, que...
function generate (line 166) | func generate(req *plugin.GenerateRequest, options *opts.Options, enums ...
function usesCopyFrom (line 336) | func usesCopyFrom(queries []Query) bool {
function usesBatch (line 345) | func usesBatch(queries []Query) bool {
function checkNoTimesForMySQLCopyFrom (line 356) | func checkNoTimesForMySQLCopyFrom(queries []Query) error {
function filterUnusedStructs (line 370) | func filterUnusedStructs(enums []Enum, structs []Struct, queries []Query...
FILE: internal/codegen/golang/go_type.go
function addExtraGoStructTags (line 11) | func addExtraGoStructTags(tags map[string]string, req *plugin.GenerateRe...
function goType (line 42) | func goType(req *plugin.GenerateRequest, options *opts.Options, col *plu...
function goInnerType (line 72) | func goInnerType(req *plugin.GenerateRequest, options *opts.Options, col...
FILE: internal/codegen/golang/imports.go
type fileImports (line 12) | type fileImports struct
type ImportSpec (line 17) | type ImportSpec struct
method String (line 22) | func (s ImportSpec) String() string {
function mergeImports (line 30) | func mergeImports(imps ...fileImports) [][]ImportSpec {
type importer (line 60) | type importer struct
method usesType (line 67) | func (i *importer) usesType(typ string) bool {
method HasImports (line 78) | func (i *importer) HasImports(filename string) bool {
method Imports (line 83) | func (i *importer) Imports(filename string) [][]ImportSpec {
method dbImports (line 121) | func (i *importer) dbImports() fileImports {
method interfaceImports (line 249) | func (i *importer) interfaceImports() fileImports {
method modelImports (line 274) | func (i *importer) modelImports() fileImports {
method queryImports (line 299) | func (i *importer) queryImports(filename string) fileImports {
method copyfromImports (line 412) | func (i *importer) copyfromImports() fileImports {
method batchImports (line 447) | func (i *importer) batchImports() fileImports {
function buildImports (line 163) | func buildImports(options *opts.Options, queries []Query, uses func(stri...
function sortedImports (line 285) | func sortedImports(std map[string]struct{}, pkg map[ImportSpec]struct{})...
function trimSliceAndPointerPrefix (line 497) | func trimSliceAndPointerPrefix(v string) string {
function hasPrefixIgnoringSliceAndPointerPrefix (line 503) | func hasPrefixIgnoringSliceAndPointerPrefix(s, prefix string) bool {
function replaceConflictedArg (line 509) | func replaceConflictedArg(imports [][]ImportSpec, queries []Query) []Que...
FILE: internal/codegen/golang/mysql_type.go
function mysqlType (line 12) | func mysqlType(req *plugin.GenerateRequest, options *opts.Options, col *...
FILE: internal/codegen/golang/opts/enum.go
type SQLDriver (line 5) | type SQLDriver
method IsPGX (line 47) | func (d SQLDriver) IsPGX() bool {
method IsGoSQLDriverMySQL (line 51) | func (d SQLDriver) IsGoSQLDriverMySQL() bool {
method Package (line 55) | func (d SQLDriver) Package() string {
constant SQLPackagePGXV4 (line 8) | SQLPackagePGXV4 string = "pgx/v4"
constant SQLPackagePGXV5 (line 9) | SQLPackagePGXV5 string = "pgx/v5"
constant SQLPackageStandard (line 10) | SQLPackageStandard string = "database/sql"
function validatePackage (line 19) | func validatePackage(sqlPackage string) error {
constant SQLDriverPGXV4 (line 27) | SQLDriverPGXV4 SQLDriver = "github.com/jackc/pgx/v4"
constant SQLDriverPGXV5 (line 28) | SQLDriverPGXV5 = "github.com/jackc/pgx/v5"
constant SQLDriverLibPQ (line 29) | SQLDriverLibPQ = "github.com/lib/pq"
constant SQLDriverGoSQLDriverMySQL (line 30) | SQLDriverGoSQLDriverMySQL = "github.com/go-sql-driver/mysql"
function validateDriver (line 40) | func validateDriver(sqlDriver string) error {
FILE: internal/codegen/golang/opts/go_type.go
type GoType (line 13) | type GoType struct
method MarshalJSON (line 31) | func (o *GoType) MarshalJSON() ([]byte, error) {
method UnmarshalJSON (line 39) | func (o *GoType) UnmarshalJSON(data []byte) error {
method UnmarshalYAML (line 54) | func (o *GoType) UnmarshalYAML(unmarshal func(interface{}) error) error {
method parse (line 88) | func (gt GoType) parse() (*ParsedGoType, error) {
type ParsedGoType (line 23) | type ParsedGoType struct
function generatePackageID (line 73) | func generatePackageID(importPath string) (string, bool) {
type GoStructTag (line 171) | type GoStructTag
method parse (line 182) | func (s GoStructTag) parse() (map[string]string, error) {
FILE: internal/codegen/golang/opts/options.go
type Options (line 12) | type Options struct
type GlobalOptions (line 52) | type GlobalOptions struct
function Parse (line 57) | func Parse(req *plugin.GenerateRequest) (*Options, error) {
function parseOpts (line 78) | func parseOpts(req *plugin.GenerateRequest) (*Options, error) {
function parseGlobalOpts (line 131) | func parseGlobalOpts(req *plugin.GenerateRequest) (*GlobalOptions, error) {
function ValidateOpts (line 147) | func ValidateOpts(opts *Options) error {
FILE: internal/codegen/golang/opts/override.go
type Override (line 13) | type Override struct
method Matches (line 54) | func (o *Override) Matches(n *plugin.Identifier, defaultSchema string)...
method MatchesColumn (line 80) | func (o *Override) MatchesColumn(col *plugin.Column) bool {
method parse (line 86) | func (o *Override) parse(req *plugin.GenerateRequest) (err error) {
FILE: internal/codegen/golang/opts/override_test.go
function TestTypeOverrides (line 9) | func TestTypeOverrides(t *testing.T) {
function FuzzOverride (line 103) | func FuzzOverride(f *testing.F) {
FILE: internal/codegen/golang/opts/shim.go
type ShimOverride (line 14) | type ShimOverride struct
function shimOverride (line 24) | func shimOverride(req *plugin.GenerateRequest, o *Override) *ShimOverride {
type ShimGoType (line 57) | type ShimGoType struct
function shimGoType (line 65) | func shimGoType(o *Override) *ShimGoType {
FILE: internal/codegen/golang/postgresql_type.go
function parseIdentifierString (line 14) | func parseIdentifierString(name string) (*plugin.Identifier, error) {
function postgresType (line 37) | func postgresType(req *plugin.GenerateRequest, options *opts.Options, co...
FILE: internal/codegen/golang/query.go
type QueryValue (line 12) | type QueryValue struct
method EmitStruct (line 26) | func (v QueryValue) EmitStruct() bool {
method IsStruct (line 30) | func (v QueryValue) IsStruct() bool {
method IsPointer (line 34) | func (v QueryValue) IsPointer() bool {
method isEmpty (line 38) | func (v QueryValue) isEmpty() bool {
method Pair (line 47) | func (v QueryValue) Pair() string {
method Pairs (line 57) | func (v QueryValue) Pairs() []Argument {
method SlicePair (line 79) | func (v QueryValue) SlicePair() string {
method Type (line 86) | func (v QueryValue) Type() string {
method DefineType (line 96) | func (v *QueryValue) DefineType() string {
method ReturnName (line 104) | func (v *QueryValue) ReturnName() string {
method UniqueFields (line 111) | func (v QueryValue) UniqueFields() []Field {
method Params (line 126) | func (v QueryValue) Params() string {
method ColumnNames (line 153) | func (v QueryValue) ColumnNames() []string {
method ColumnNamesAsGoSlice (line 164) | func (v QueryValue) ColumnNamesAsGoSlice() string {
method HasSqlcSlices (line 181) | func (v QueryValue) HasSqlcSlices() bool {
method Scan (line 193) | func (v QueryValue) Scan() string {
method CopyFromMySQLFields (line 233) | func (v QueryValue) CopyFromMySQLFields() []Field {
method VariableForField (line 247) | func (v QueryValue) VariableForField(f Field) string {
type Argument (line 42) | type Argument struct
type Query (line 258) | type Query struct
method hasRetType (line 272) | func (q Query) hasRetType() bool {
method TableIdentifierAsGoSlice (line 278) | func (q Query) TableIdentifierAsGoSlice() string {
method TableIdentifierForMySQL (line 288) | func (q Query) TableIdentifierForMySQL() string {
FILE: internal/codegen/golang/reserved.go
function escape (line 3) | func escape(s string) string {
function IsReserved (line 10) | func IsReserved(s string) bool {
FILE: internal/codegen/golang/result.go
function buildEnums (line 16) | func buildEnums(req *plugin.GenerateRequest, options *opts.Options) []En...
function buildStructs (line 63) | func buildStructs(req *plugin.GenerateRequest, options *opts.Options) []...
type goColumn (line 113) | type goColumn struct
type goEmbed (line 119) | type goEmbed struct
function newGoEmbed (line 127) | func newGoEmbed(embed *plugin.Identifier, structs []Struct, defaultSchem...
function columnName (line 156) | func columnName(c *plugin.Column, pos int) string {
function paramName (line 163) | func paramName(p *plugin.Parameter) string {
function argName (line 170) | func argName(name string) string {
function buildQueries (line 184) | func buildQueries(req *plugin.GenerateRequest, options *opts.Options, st...
function putOutColumns (line 339) | func putOutColumns(query *plugin.Query) bool {
function columnsToStruct (line 352) | func columnsToStruct(req *plugin.GenerateRequest, options *opts.Options,...
function checkIncompatibleFieldTypes (line 438) | func checkIncompatibleFieldTypes(fields []Field) error {
FILE: internal/codegen/golang/result_test.go
function TestPutOutColumns_ForZeroColumns (line 10) | func TestPutOutColumns_ForZeroColumns(t *testing.T) {
function TestPutOutColumns_AlwaysTrueWhenQueryHasColumns (line 70) | func TestPutOutColumns_AlwaysTrueWhenQueryHasColumns(t *testing.T) {
FILE: internal/codegen/golang/sqlite_type.go
function sqliteType (line 13) | func sqliteType(req *plugin.GenerateRequest, options *opts.Options, col ...
FILE: internal/codegen/golang/struct.go
type Struct (line 12) | type Struct struct
function StructName (line 19) | func StructName(name string, options *opts.Options) string {
FILE: internal/codegen/json/gen.go
function parseOptions (line 14) | func parseOptions(req *plugin.GenerateRequest) (*opts, error) {
function Generate (line 28) | func Generate(ctx context.Context, req *plugin.GenerateRequest) (*plugin...
FILE: internal/codegen/json/opts.go
type opts (line 3) | type opts struct
FILE: internal/codegen/sdk/sdk.go
function DataType (line 8) | func DataType(n *plugin.Identifier) string {
function MatchString (line 16) | func MatchString(pat, target string) bool {
function SameTableName (line 24) | func SameTableName(tableID, f *plugin.Identifier, defaultSchema string) ...
FILE: internal/codegen/sdk/utils.go
function LowerTitle (line 8) | func LowerTitle(s string) string {
function Title (line 18) | func Title(s string) string {
function EscapeBacktick (line 36) | func EscapeBacktick(s string) string {
function DoubleSlashComment (line 40) | func DoubleSlashComment(s string) string {
FILE: internal/codegen/sdk/utils_test.go
function TestLowerTitle (line 7) | func TestLowerTitle(t *testing.T) {
FILE: internal/compiler/analyze.go
type analysis (line 15) | type analysis struct
function convertTableName (line 23) | func convertTableName(id *analyzer.Identifier) *ast.TableName {
function convertTypeName (line 34) | func convertTypeName(id *analyzer.Identifier) *ast.TypeName {
function convertColumn (line 45) | func convertColumn(c *analyzer.Column) *Column {
function combineAnalysis (line 68) | func combineAnalysis(prev *analysis, a *analyzer.Analysis) *analysis {
method analyzeQuery (line 117) | func (c *Compiler) analyzeQuery(raw *ast.RawStmt, query string) (*analys...
method inferQuery (line 121) | func (c *Compiler) inferQuery(raw *ast.RawStmt, query string) (*analysis...
method _analyzeQuery (line 125) | func (c *Compiler) _analyzeQuery(raw *ast.RawStmt, query string, failfas...
FILE: internal/compiler/compat.go
function stringSlice (line 12) | func stringSlice(list *ast.List) []string {
type Relation (line 22) | type Relation struct
function parseRelation (line 28) | func parseRelation(node ast.Node) (*Relation, error) {
function ParseTableName (line 92) | func ParseTableName(node ast.Node) (*ast.TableName, error) {
function ParseTypeName (line 104) | func ParseTypeName(node ast.Node) (*ast.TypeName, error) {
function ParseRelationString (line 116) | func ParseRelationString(name string) (*Relation, error) {
FILE: internal/compiler/compile.go
type Parser (line 23) | type Parser interface
method parseCatalog (line 29) | func (c *Compiler) parseCatalog(schemas []string) error {
method parseQueries (line 70) | func (c *Compiler) parseQueries(o opts.Parser) (*Result, error) {
FILE: internal/compiler/engine.go
type Compiler (line 20) | type Compiler struct
method Catalog (line 120) | func (c *Compiler) Catalog() *catalog.Catalog {
method ParseCatalog (line 124) | func (c *Compiler) ParseCatalog(schema []string) error {
method ParseQueries (line 128) | func (c *Compiler) ParseQueries(queries []string, o opts.Parser) error {
method Result (line 137) | func (c *Compiler) Result() *Result {
method Close (line 141) | func (c *Compiler) Close(ctx context.Context) {
function NewCompiler (line 39) | func NewCompiler(conf config.SQL, combo config.CombinedSettings, parserO...
FILE: internal/compiler/expand.go
method expand (line 14) | func (c *Compiler) expand(qc *QueryCatalog, raw *ast.RawStmt) ([]source....
method quoteIdent (line 50) | func (c *Compiler) quoteIdent(ident string) string {
method quote (line 72) | func (c *Compiler) quote(x string) string {
method expandStmt (line 81) | func (c *Compiler) expandStmt(qc *QueryCatalog, raw *ast.RawStmt, node a...
FILE: internal/compiler/find_params.go
function findParameters (line 10) | func findParameters(root ast.Node) ([]paramRef, []error) {
type paramRef (line 22) | type paramRef struct
type paramSearch (line 29) | type paramSearch struct
method Visit (line 55) | func (p paramSearch) Visit(node ast.Node) astutils.Visitor {
type limitCount (line 41) | type limitCount struct
method Pos (line 44) | func (l *limitCount) Pos() int {
type limitOffset (line 48) | type limitOffset struct
method Pos (line 51) | func (l *limitOffset) Pos() int {
FILE: internal/compiler/output_columns.go
method OutputColumns (line 15) | func (c *Compiler) OutputColumns(stmt ast.Node) ([]*catalog.Column, erro...
function hasStarRef (line 41) | func hasStarRef(cf *ast.ColumnRef) bool {
method outputColumns (line 54) | func (c *Compiler) outputColumns(qc *QueryCatalog, node ast.Node) ([]*Co...
constant tableNotFound (line 411) | tableNotFound = iota
constant tableRequired (line 412) | tableRequired
constant tableOptional (line 413) | tableOptional
function isTableRequired (line 416) | func isTableRequired(n ast.Node, col *Column, prior int) int {
type tableVisitor (line 458) | type tableVisitor struct
method Visit (line 462) | func (r *tableVisitor) Visit(n ast.Node) astutils.Visitor {
method sourceTables (line 481) | func (c *Compiler) sourceTables(qc *QueryCatalog, node ast.Node) ([]*Tab...
function outputColumnRefs (line 650) | func outputColumnRefs(res *ast.ResTarget, tables []*Table, node *ast.Col...
function findColumnForNode (line 717) | func findColumnForNode(item ast.Node, tables []*Table, targetList *ast.L...
function findColumnForRef (line 725) | func findColumnForRef(ref *ast.ColumnRef, tables []*Table, targetList *a...
FILE: internal/compiler/parse.go
method parseQuery (line 18) | func (c *Compiler) parseQuery(stmt ast.Node, src string, o opts.Parser) ...
function rangeVars (line 184) | func rangeVars(root ast.Node) []*ast.RangeVar {
function uniqueParamRefs (line 196) | func uniqueParamRefs(in []paramRef, dollar bool) []paramRef {
FILE: internal/compiler/query.go
type Function (line 9) | type Function struct
type Table (line 15) | type Table struct
type Column (line 20) | type Column struct
type Query (line 45) | type Query struct
type Parameter (line 58) | type Parameter struct
FILE: internal/compiler/query_catalog.go
type QueryCatalog (line 11) | type QueryCatalog struct
method GetTable (line 80) | func (qc QueryCatalog) GetTable(rel *ast.TableName) (*Table, error) {
method GetFunc (line 96) | func (qc QueryCatalog) GetFunc(rel *ast.FuncName) (*Function, error) {
method buildQueryCatalog (line 17) | func (comp *Compiler) buildQueryCatalog(c *catalog.Catalog, node ast.Nod...
function ConvertColumn (line 66) | func ConvertColumn(rel *ast.TableName, c *catalog.Column) *Column {
FILE: internal/compiler/resolve.go
function dataType (line 16) | func dataType(n *ast.TypeName) string {
method resolveCatalogRefs (line 24) | func (comp *Compiler) resolveCatalogRefs(qc *QueryCatalog, rvs []*ast.Ra...
FILE: internal/compiler/result.go
type Result (line 7) | type Result struct
FILE: internal/compiler/selector.go
type selector (line 9) | type selector interface
type defaultSelector (line 18) | type defaultSelector struct
method ColumnExpr (line 24) | func (s *defaultSelector) ColumnExpr(name string, column *Column) stri...
function newDefaultSelector (line 20) | func newDefaultSelector() *defaultSelector {
type sqliteSelector (line 28) | type sqliteSelector struct
method ColumnExpr (line 34) | func (s *sqliteSelector) ColumnExpr(name string, column *Column) string {
function newSQLiteSelector (line 30) | func newSQLiteSelector() *sqliteSelector {
FILE: internal/compiler/selector_test.go
function TestSelector (line 5) | func TestSelector(t *testing.T) {
FILE: internal/compiler/to_column.go
function arrayDims (line 10) | func arrayDims(n *ast.TypeName) int {
function toColumn (line 17) | func toColumn(n *ast.TypeName) *Column {
FILE: internal/config/config.go
type versionSetting (line 14) | type versionSetting struct
type Engine (line 18) | type Engine
type Paths (line 20) | type Paths
method UnmarshalJSON (line 22) | func (p *Paths) UnmarshalJSON(data []byte) error {
method UnmarshalYAML (line 39) | func (p *Paths) UnmarshalYAML(unmarshal func(interface{}) error) error {
constant EngineMySQL (line 54) | EngineMySQL Engine = "mysql"
constant EnginePostgreSQL (line 55) | EnginePostgreSQL Engine = "postgresql"
constant EngineSQLite (line 56) | EngineSQLite Engine = "sqlite"
type Config (line 59) | type Config struct
type Server (line 70) | type Server struct
type Database (line 76) | type Database struct
type Cloud (line 81) | type Cloud struct
type Plugin (line 88) | type Plugin struct
type Rule (line 101) | type Rule struct
type Overrides (line 107) | type Overrides struct
type SQL (line 111) | type SQL struct
type AnalyzerDatabase (line 127) | type AnalyzerDatabase struct
method IsEnabled (line 134) | func (a AnalyzerDatabase) IsEnabled() bool {
method IsOnly (line 142) | func (a AnalyzerDatabase) IsOnly() bool {
method UnmarshalJSON (line 146) | func (a *AnalyzerDatabase) UnmarshalJSON(data []byte) error {
method UnmarshalYAML (line 169) | func (a *AnalyzerDatabase) UnmarshalYAML(unmarshal func(interface{}) e...
type Analyzer (line 192) | type Analyzer struct
type Codegen (line 197) | type Codegen struct
type SQLGen (line 203) | type SQLGen struct
type SQLJSON (line 208) | type SQLJSON struct
function ParseConfig (line 245) | func ParseConfig(rd io.Reader) (Config, error) {
type CombinedSettings (line 280) | type CombinedSettings struct
function Combine (line 290) | func Combine(conf Config, pkg SQL) CombinedSettings {
FILE: internal/config/config_test.go
constant missingVersion (line 10) | missingVersion = `{
constant missingPackages (line 13) | missingPackages = `{
constant unknownVersion (line 17) | unknownVersion = `{
constant unknownFields (line 21) | unknownFields = `{
function TestBadConfigs (line 26) | func TestBadConfigs(t *testing.T) {
constant validConfigOne (line 67) | validConfigOne = `{
function FuzzConfig (line 72) | func FuzzConfig(f *testing.F) {
function TestInvalidConfig (line 79) | func TestInvalidConfig(t *testing.T) {
FILE: internal/config/convert/convert.go
function gen (line 11) | func gen(n *yaml.Node) (interface{}, error) {
function YAMLtoJSON (line 71) | func YAMLtoJSON(n yaml.Node) ([]byte, error) {
FILE: internal/config/convert/convert_test.go
constant anchor (line 9) | anchor = `
type config (line 34) | type config struct
function TestAlias (line 38) | func TestAlias(t *testing.T) {
FILE: internal/config/env.go
method addEnvVars (line 9) | func (c *Config) addEnvVars() error {
FILE: internal/config/v_one.go
type V1GenerateSettings (line 13) | type V1GenerateSettings struct
method ValidateGlobalOverrides (line 101) | func (c *V1GenerateSettings) ValidateGlobalOverrides() error {
method Translate (line 118) | func (c *V1GenerateSettings) Translate() Config {
type v1PackageSettings (line 22) | type v1PackageSettings struct
function v1ParseConfig (line 64) | func v1ParseConfig(rd io.Reader) (Config, error) {
FILE: internal/config/v_two.go
function v2ParseConfig (line 10) | func v2ParseConfig(rd io.Reader) (Config, error) {
method validateGlobalOverrides (line 92) | func (c *Config) validateGlobalOverrides() error {
FILE: internal/config/validate.go
function Validate (line 3) | func Validate(c *Config) error {
FILE: internal/constants/query.go
constant QueryFlagParam (line 5) | QueryFlagParam = "@param"
constant QueryFlagSqlcVetDisable (line 6) | QueryFlagSqlcVetDisable = "@sqlc-vet-disable"
constant QueryRuleDbPrepare (line 11) | QueryRuleDbPrepare = "sqlc/db-prepare"
FILE: internal/dbmanager/client.go
type CreateDatabaseRequest (line 19) | type CreateDatabaseRequest struct
type CreateDatabaseResponse (line 25) | type CreateDatabaseResponse struct
type Client (line 29) | type Client interface
type ManagedClient (line 36) | type ManagedClient struct
method CreateDatabase (line 50) | func (m *ManagedClient) CreateDatabase(ctx context.Context, req *Creat...
method Close (line 140) | func (m *ManagedClient) Close(ctx context.Context) {
function dbid (line 42) | func dbid(migrations []string) string {
function NewClient (line 144) | func NewClient(servers []config.Server) *ManagedClient {
FILE: internal/debug/dump.go
function init (line 16) | func init() {
function Dump (line 23) | func Dump(n ...interface{}) {
function DumpAsJSON (line 29) | func DumpAsJSON(a any) {
FILE: internal/endtoend/case_test.go
type Testcase (line 13) | type Testcase struct
type ExecMeta (line 21) | type ExecMeta struct
type Exec (line 25) | type Exec struct
function parseStderr (line 34) | func parseStderr(t *testing.T, dir, testctx string) []byte {
function parseExec (line 53) | func parseExec(t *testing.T, dir string) *Exec {
function FindTests (line 73) | func FindTests(t *testing.T, root, testctx string) []*Testcase {
FILE: internal/endtoend/ddl_test.go
function TestValidSchema (line 13) | func TestValidSchema(t *testing.T) {
FILE: internal/endtoend/endtoend_test.go
function lineEndings (line 24) | func lineEndings() cmp.Option {
function stderrTransformer (line 31) | func stderrTransformer() cmp.Option {
function TestExamples (line 38) | func TestExamples(t *testing.T) {
function BenchmarkExamples (line 74) | func BenchmarkExamples(b *testing.B) {
type textContext (line 103) | type textContext struct
function TestReplay (line 108) | func TestReplay(t *testing.T) {
function cmpDirectory (line 305) | func cmpDirectory(t *testing.T, dir string, actual map[string]string) {
function BenchmarkReplay (line 369) | func BenchmarkReplay(b *testing.B) {
FILE: internal/endtoend/fmt_test.go
type sqlParser (line 22) | type sqlParser interface
type sqlFormatter (line 27) | type sqlFormatter interface
function TestFormat (line 31) | func TestFormat(t *testing.T) {
FILE: internal/endtoend/json_schema_test.go
type conf (line 13) | type conf struct
function loadSchema (line 17) | func loadSchema(t *testing.T, path string) *gojsonschema.Schema {
function TestJsonSchema (line 33) | func TestJsonSchema(t *testing.T) {
FILE: internal/endtoend/testdata/accurate_cte/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/accurate_cte/postgresql/stdlib/go/models.go
type Product (line 7) | type Product struct
FILE: internal/endtoend/testdata/accurate_cte/postgresql/stdlib/go/query.sql.go
constant getProductStats (line 12) | getProductStats = `-- name: GetProductStats :one
type GetProductStatsRow (line 19) | type GetProductStatsRow struct
method GetProductStats (line 24) | func (q *Queries) GetProductStats(ctx context.Context) (GetProductStatsR...
constant listExpensiveProducts (line 31) | listExpensiveProducts = `-- name: ListExpensiveProducts :many
type ListExpensiveProductsRow (line 38) | type ListExpensiveProductsRow struct
method ListExpensiveProducts (line 44) | func (q *Queries) ListExpensiveProducts(ctx context.Context) ([]ListExpe...
FILE: internal/endtoend/testdata/accurate_cte/postgresql/stdlib/schema.sql
type products (line 1) | CREATE TABLE products (
FILE: internal/endtoend/testdata/accurate_enum/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/accurate_enum/postgresql/stdlib/go/models.go
type Status (line 12) | type Status
method Scan (line 20) | func (e *Status) Scan(src interface{}) error {
constant StatusPending (line 15) | StatusPending Status = "pending"
constant StatusActive (line 16) | StatusActive Status = "active"
constant StatusCompleted (line 17) | StatusCompleted Status = "completed"
type NullStatus (line 32) | type NullStatus struct
method Scan (line 38) | func (ns *NullStatus) Scan(value interface{}) error {
method Value (line 48) | func (ns NullStatus) Value() (driver.Value, error) {
type Task (line 55) | type Task struct
FILE: internal/endtoend/testdata/accurate_enum/postgresql/stdlib/go/query.sql.go
constant createTask (line 12) | createTask = `-- name: CreateTask :one
type CreateTaskParams (line 16) | type CreateTaskParams struct
method CreateTask (line 21) | func (q *Queries) CreateTask(ctx context.Context, arg CreateTaskParams) ...
constant getTasksByStatus (line 28) | getTasksByStatus = `-- name: GetTasksByStatus :many
method GetTasksByStatus (line 32) | func (q *Queries) GetTasksByStatus(ctx context.Context, status Status) (...
constant listTasks (line 55) | listTasks = `-- name: ListTasks :many
method ListTasks (line 59) | func (q *Queries) ListTasks(ctx context.Context) ([]Task, error) {
FILE: internal/endtoend/testdata/accurate_enum/postgresql/stdlib/schema.sql
type tasks (line 3) | CREATE TABLE tasks (
FILE: internal/endtoend/testdata/accurate_sqlite/sqlite/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/accurate_sqlite/sqlite/stdlib/go/models.go
type Author (line 11) | type Author struct
FILE: internal/endtoend/testdata/accurate_sqlite/sqlite/stdlib/go/query.sql.go
constant createAuthor (line 13) | createAuthor = `-- name: CreateAuthor :one
type CreateAuthorParams (line 17) | type CreateAuthorParams struct
method CreateAuthor (line 22) | func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorPara...
constant getAuthor (line 29) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 33) | func (q *Queries) GetAuthor(ctx context.Context, id int64) (Author, erro...
constant listAuthors (line 40) | listAuthors = `-- name: ListAuthors :many
method ListAuthors (line 44) | func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
FILE: internal/endtoend/testdata/accurate_sqlite/sqlite/stdlib/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/accurate_star_expansion/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/accurate_star_expansion/postgresql/stdlib/go/models.go
type Author (line 11) | type Author struct
FILE: internal/endtoend/testdata/accurate_star_expansion/postgresql/stdlib/go/query.sql.go
constant createAuthor (line 13) | createAuthor = `-- name: CreateAuthor :one
type CreateAuthorParams (line 17) | type CreateAuthorParams struct
method CreateAuthor (line 22) | func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorPara...
constant deleteAuthor (line 29) | deleteAuthor = `-- name: DeleteAuthor :one
method DeleteAuthor (line 33) | func (q *Queries) DeleteAuthor(ctx context.Context, id int32) (Author, e...
constant getAuthor (line 40) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 44) | func (q *Queries) GetAuthor(ctx context.Context, id int32) (Author, erro...
constant listAuthors (line 51) | listAuthors = `-- name: ListAuthors :many
method ListAuthors (line 55) | func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
constant updateAuthor (line 78) | updateAuthor = `-- name: UpdateAuthor :one
type UpdateAuthorParams (line 82) | type UpdateAuthorParams struct
method UpdateAuthor (line 88) | func (q *Queries) UpdateAuthor(ctx context.Context, arg UpdateAuthorPara...
FILE: internal/endtoend/testdata/accurate_star_expansion/postgresql/stdlib/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/alias/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/alias/mysql/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/alias/mysql/go/query.sql.go
constant aliasBar (line 12) | aliasBar = `-- name: AliasBar :exec
method AliasBar (line 17) | func (q *Queries) AliasBar(ctx context.Context, id uint64) error {
FILE: internal/endtoend/testdata/alias/mysql/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v4/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v4/go/query.sql.go
constant aliasBar (line 12) | aliasBar = `-- name: AliasBar :exec
method AliasBar (line 17) | func (q *Queries) AliasBar(ctx context.Context, id int32) error {
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v4/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v5/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v5/go/query.sql.go
constant aliasBar (line 12) | aliasBar = `-- name: AliasBar :exec
method AliasBar (line 17) | func (q *Queries) AliasBar(ctx context.Context, id int32) error {
FILE: internal/endtoend/testdata/alias/postgresql/pgx/v5/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/alias/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/alias/postgresql/stdlib/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/alias/postgresql/stdlib/go/query.sql.go
constant aliasBar (line 12) | aliasBar = `-- name: AliasBar :exec
method AliasBar (line 17) | func (q *Queries) AliasBar(ctx context.Context, id int32) error {
FILE: internal/endtoend/testdata/alias/postgresql/stdlib/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/alias/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/alias/sqlite/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/alias/sqlite/go/query.sql.go
constant aliasBar (line 12) | aliasBar = `-- name: AliasBar :exec
method AliasBar (line 17) | func (q *Queries) AliasBar(ctx context.Context, id int64) error {
FILE: internal/endtoend/testdata/alias/sqlite/schema.sql
type bar (line 1) | CREATE TABLE bar (id integer NOT NULL PRIMARY KEY AUTOINCREMENT)
FILE: internal/endtoend/testdata/any/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/any/pgx/v4/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/any/pgx/v4/go/query.sql.go
constant any (line 12) | any = `-- name: Any :many
method Any (line 18) | func (q *Queries) Any(ctx context.Context, dollar_1 []int64) ([]int64, e...
FILE: internal/endtoend/testdata/any/pgx/v4/schema.sql
type bar (line 1) | CREATE TABLE bar (id bigserial not null)
FILE: internal/endtoend/testdata/any/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/any/pgx/v5/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/any/pgx/v5/go/query.sql.go
constant any (line 12) | any = `-- name: Any :many
method Any (line 18) | func (q *Queries) Any(ctx context.Context, dollar_1 []int64) ([]int64, e...
FILE: internal/endtoend/testdata/any/pgx/v5/schema.sql
type bar (line 1) | CREATE TABLE bar (id bigserial not null)
FILE: internal/endtoend/testdata/any/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/any/stdlib/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/any/stdlib/go/query.sql.go
constant any (line 14) | any = `-- name: Any :many
method Any (line 20) | func (q *Queries) Any(ctx context.Context, dollar_1 []int64) ([]int64, e...
FILE: internal/endtoend/testdata/any/stdlib/schema.sql
type bar (line 1) | CREATE TABLE bar (id bigserial not null)
FILE: internal/endtoend/testdata/array_in/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/array_in/pgx/v4/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/array_in/pgx/v4/go/query.sql.go
constant in (line 12) | in = `-- name: In :many
type InParams (line 18) | type InParams struct
method In (line 23) | func (q *Queries) In(ctx context.Context, arg InParams) ([]int32, error) {
FILE: internal/endtoend/testdata/array_in/pgx/v4/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/array_in/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/array_in/pgx/v5/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/array_in/pgx/v5/go/query.sql.go
constant in (line 12) | in = `-- name: In :many
type InParams (line 18) | type InParams struct
method In (line 23) | func (q *Queries) In(ctx context.Context, arg InParams) ([]int32, error) {
FILE: internal/endtoend/testdata/array_in/pgx/v5/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/array_in/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/array_in/stdlib/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/array_in/stdlib/go/query.sql.go
constant in (line 12) | in = `-- name: In :many
type InParams (line 18) | type InParams struct
method In (line 23) | func (q *Queries) In(ctx context.Context, arg InParams) ([]int32, error) {
FILE: internal/endtoend/testdata/array_in/stdlib/schema.sql
type bar (line 1) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/array_text/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/array_text/pgx/v4/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/array_text/pgx/v4/go/query.sql.go
constant textArray (line 12) | textArray = `-- name: TextArray :many
method TextArray (line 16) | func (q *Queries) TextArray(ctx context.Context) ([][]string, error) {
FILE: internal/endtoend/testdata/array_text/pgx/v4/schema.sql
type bar (line 1) | CREATE TABLE bar (tags text[] not null)
FILE: internal/endtoend/testdata/array_text/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/array_text/pgx/v5/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/array_text/pgx/v5/go/query.sql.go
constant textArray (line 12) | textArray = `-- name: TextArray :many
method TextArray (line 16) | func (q *Queries) TextArray(ctx context.Context) ([][]string, error) {
FILE: internal/endtoend/testdata/array_text/pgx/v5/schema.sql
type bar (line 1) | CREATE TABLE bar (tags text[] not null)
FILE: internal/endtoend/testdata/array_text/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/array_text/stdlib/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/array_text/stdlib/go/query.sql.go
constant textArray (line 14) | textArray = `-- name: TextArray :many
method TextArray (line 18) | func (q *Queries) TextArray(ctx context.Context) ([][]string, error) {
FILE: internal/endtoend/testdata/array_text/stdlib/schema.sql
type bar (line 1) | CREATE TABLE bar (tags text[] not null)
FILE: internal/endtoend/testdata/array_text_join/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/array_text_join/pgx/v4/go/models.go
type Bar (line 7) | type Bar struct
type Foo (line 12) | type Foo struct
FILE: internal/endtoend/testdata/array_text_join/pgx/v4/go/query.sql.go
constant joinTextArray (line 12) | joinTextArray = `-- name: JoinTextArray :many
method JoinTextArray (line 18) | func (q *Queries) JoinTextArray(ctx context.Context) ([][]string, error) {
FILE: internal/endtoend/testdata/array_text_join/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null, bar text not null)
type bar (line 2) | CREATE TABLE bar (id text not null, info text[] not null)
FILE: internal/endtoend/testdata/array_text_join/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/array_text_join/pgx/v5/go/models.go
type Bar (line 7) | type Bar struct
type Foo (line 12) | type Foo struct
FILE: internal/endtoend/testdata/array_text_join/pgx/v5/go/query.sql.go
constant joinTextArray (line 12) | joinTextArray = `-- name: JoinTextArray :many
method JoinTextArray (line 18) | func (q *Queries) JoinTextArray(ctx context.Context) ([][]string, error) {
FILE: internal/endtoend/testdata/array_text_join/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null, bar text not null)
type bar (line 2) | CREATE TABLE bar (id text not null, info text[] not null)
FILE: internal/endtoend/testdata/array_text_join/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/array_text_join/stdlib/go/models.go
type Bar (line 7) | type Bar struct
type Foo (line 12) | type Foo struct
FILE: internal/endtoend/testdata/array_text_join/stdlib/go/query.sql.go
constant joinTextArray (line 14) | joinTextArray = `-- name: JoinTextArray :many
method JoinTextArray (line 20) | func (q *Queries) JoinTextArray(ctx context.Context) ([][]string, error) {
FILE: internal/endtoend/testdata/array_text_join/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null, bar text not null)
type bar (line 2) | CREATE TABLE bar (id text not null, info text[] not null)
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v4/go/batch.go
constant getValues (line 20) | getValues = `-- name: GetValues :batchmany
type GetValuesBatchResults (line 26) | type GetValuesBatchResults struct
method Query (line 44) | func (b *GetValuesBatchResults) Query(f func(int, []MyschemaFoo, error...
method Close (line 75) | func (b *GetValuesBatchResults) Close() error {
method GetValues (line 32) | func (q *Queries) GetValues(ctx context.Context, b []sql.NullInt32) *Get...
constant insertValues (line 80) | insertValues = `-- name: InsertValues :batchone
type InsertValuesBatchResults (line 86) | type InsertValuesBatchResults struct
method QueryRow (line 110) | func (b *InsertValuesBatchResults) QueryRow(f func(int, sql.NullString...
method Close (line 128) | func (b *InsertValuesBatchResults) Close() error {
type InsertValuesParams (line 92) | type InsertValuesParams struct
method InsertValues (line 97) | func (q *Queries) InsertValues(ctx context.Context, arg []InsertValuesPa...
constant updateValues (line 133) | updateValues = `-- name: UpdateValues :batchexec
type UpdateValuesBatchResults (line 137) | type UpdateValuesBatchResults struct
method Exec (line 161) | func (b *UpdateValuesBatchResults) Exec(f func(int, error)) {
method Close (line 177) | func (b *UpdateValuesBatchResults) Close() error {
type UpdateValuesParams (line 143) | type UpdateValuesParams struct
method UpdateValues (line 148) | func (q *Queries) UpdateValues(ctx context.Context, arg []UpdateValuesPa...
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v4/go/models.go
type MyschemaFoo (line 11) | type MyschemaFoo struct
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v4/schema.sql
type myschema (line 2) | CREATE TABLE myschema.foo (a text, b integer)
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v5/go/batch.go
constant getValues (line 20) | getValues = `-- name: GetValues :batchmany
type GetValuesBatchResults (line 26) | type GetValuesBatchResults struct
method Query (line 44) | func (b *GetValuesBatchResults) Query(f func(int, []MyschemaFoo, error...
method Close (line 75) | func (b *GetValuesBatchResults) Close() error {
method GetValues (line 32) | func (q *Queries) GetValues(ctx context.Context, b []pgtype.Int4) *GetVa...
constant insertValues (line 80) | insertValues = `-- name: InsertValues :batchone
type InsertValuesBatchResults (line 86) | type InsertValuesBatchResults struct
method QueryRow (line 110) | func (b *InsertValuesBatchResults) QueryRow(f func(int, pgtype.Text, e...
method Close (line 128) | func (b *InsertValuesBatchResults) Close() error {
type InsertValuesParams (line 92) | type InsertValuesParams struct
method InsertValues (line 97) | func (q *Queries) InsertValues(ctx context.Context, arg []InsertValuesPa...
constant updateValues (line 133) | updateValues = `-- name: UpdateValues :batchexec
type UpdateValuesBatchResults (line 137) | type UpdateValuesBatchResults struct
method Exec (line 161) | func (b *UpdateValuesBatchResults) Exec(f func(int, error)) {
method Close (line 177) | func (b *UpdateValuesBatchResults) Close() error {
type UpdateValuesParams (line 143) | type UpdateValuesParams struct
method UpdateValues (line 148) | func (q *Queries) UpdateValues(ctx context.Context, arg []UpdateValuesPa...
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v5/go/models.go
type MyschemaFoo (line 11) | type MyschemaFoo struct
FILE: internal/endtoend/testdata/batch/postgresql/pgx/v5/schema.sql
type myschema (line 2) | CREATE TABLE myschema.foo (a text, b integer)
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v4/go/batch.go
constant getValues (line 20) | getValues = `-- name: GetValues :batchmany
type GetValuesBatchResults (line 26) | type GetValuesBatchResults struct
method Query (line 44) | func (b *GetValuesBatchResults) Query(f func(int, []MyschemaFoo, error...
method Close (line 75) | func (b *GetValuesBatchResults) Close() error {
method GetValues (line 32) | func (q *Queries) GetValues(ctx context.Context, b []sql.NullInt32) *Get...
constant insertValues (line 80) | insertValues = `-- name: InsertValues :batchone
type InsertValuesBatchResults (line 86) | type InsertValuesBatchResults struct
method QueryRow (line 110) | func (b *InsertValuesBatchResults) QueryRow(f func(int, sql.NullString...
method Close (line 128) | func (b *InsertValuesBatchResults) Close() error {
type InsertValuesParams (line 92) | type InsertValuesParams struct
method InsertValues (line 97) | func (q *Queries) InsertValues(ctx context.Context, arg []InsertValuesPa...
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v4/go/models.go
type MyschemaFoo (line 11) | type MyschemaFoo struct
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v4/go/query.sql.go
constant updateValues (line 13) | updateValues = `-- name: UpdateValues :exec
type UpdateValuesParams (line 17) | type UpdateValuesParams struct
method UpdateValues (line 22) | func (q *Queries) UpdateValues(ctx context.Context, arg UpdateValuesPara...
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v4/schema.sql
type myschema (line 2) | CREATE TABLE myschema.foo (a text, b integer)
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v5/go/batch.go
constant getValues (line 20) | getValues = `-- name: GetValues :batchmany
type GetValuesBatchResults (line 26) | type GetValuesBatchResults struct
method Query (line 44) | func (b *GetValuesBatchResults) Query(f func(int, []MyschemaFoo, error...
method Close (line 75) | func (b *GetValuesBatchResults) Close() error {
method GetValues (line 32) | func (q *Queries) GetValues(ctx context.Context, b []pgtype.Int4) *GetVa...
constant insertValues (line 80) | insertValues = `-- name: InsertValues :batchone
type InsertValuesBatchResults (line 86) | type InsertValuesBatchResults struct
method QueryRow (line 110) | func (b *InsertValuesBatchResults) QueryRow(f func(int, pgtype.Text, e...
method Close (line 128) | func (b *InsertValuesBatchResults) Close() error {
type InsertValuesParams (line 92) | type InsertValuesParams struct
method InsertValues (line 97) | func (q *Queries) InsertValues(ctx context.Context, arg []InsertValuesPa...
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v5/go/models.go
type MyschemaFoo (line 11) | type MyschemaFoo struct
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v5/go/query.sql.go
constant updateValues (line 14) | updateValues = `-- name: UpdateValues :exec
type UpdateValuesParams (line 18) | type UpdateValuesParams struct
method UpdateValues (line 23) | func (q *Queries) UpdateValues(ctx context.Context, arg UpdateValuesPara...
FILE: internal/endtoend/testdata/batch_imports/postgresql/pgx/v5/schema.sql
type myschema (line 2) | CREATE TABLE myschema.foo (a text, b integer)
FILE: internal/endtoend/testdata/batch_parameter_limit/postgresql/pgx/go/batch.go
constant createAuthors (line 20) | createAuthors = `-- name: CreateAuthors :batchexec
type CreateAuthorsBatchResults (line 28) | type CreateAuthorsBatchResults struct
method Exec (line 52) | func (b *CreateAuthorsBatchResults) Exec(f func(int, error)) {
method Close (line 68) | func (b *CreateAuthorsBatchResults) Close() error {
type CreateAuthorsParams (line 34) | type CreateAuthorsParams struct
method CreateAuthors (line 39) | func (q *Queries) CreateAuthors(ctx context.Context, arg []CreateAuthors...
FILE: internal/endtoend/testdata/batch_parameter_limit/postgresql/pgx/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/batch_parameter_limit/postgresql/pgx/go/models.go
type Author (line 11) | type Author struct
FILE: internal/endtoend/testdata/batch_parameter_limit/postgresql/pgx/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/batch_parameter_type/postgresql/pgx/go/batch.go
constant insertMappping (line 20) | insertMappping = `-- name: InsertMappping :batchexec
type InsertMapppingBatchResults (line 54) | type InsertMapppingBatchResults struct
method Exec (line 82) | func (b *InsertMapppingBatchResults) Exec(f func(int, error)) {
method Close (line 98) | func (b *InsertMapppingBatchResults) Close() error {
type InsertMapppingParams (line 60) | type InsertMapppingParams struct
method InsertMappping (line 67) | func (q *Queries) InsertMappping(ctx context.Context, arg []InsertMapppi...
FILE: internal/endtoend/testdata/batch_parameter_type/postgresql/pgx/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/batch_parameter_type/postgresql/pgx/go/models.go
type SolarCommcardMapping (line 11) | type SolarCommcardMapping struct
FILE: internal/endtoend/testdata/batch_parameter_type/postgresql/pgx/schema.sql
type public (line 1) | CREATE TABLE public.solar_commcard_mapping (
FILE: internal/endtoend/testdata/between_args/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/between_args/mysql/go/models.go
type Product (line 7) | type Product struct
FILE: internal/endtoend/testdata/between_args/mysql/go/query.sql.go
constant getBetweenPrices (line 12) | getBetweenPrices = `-- name: GetBetweenPrices :many
type GetBetweenPricesParams (line 18) | type GetBetweenPricesParams struct
method GetBetweenPrices (line 23) | func (q *Queries) GetBetweenPrices(ctx context.Context, arg GetBetweenPr...
constant getBetweenPricesNamed (line 46) | getBetweenPricesNamed = `-- name: GetBetweenPricesNamed :many
type GetBetweenPricesNamedParams (line 52) | type GetBetweenPricesNamedParams struct
method GetBetweenPricesNamed (line 57) | func (q *Queries) GetBetweenPricesNamed(ctx context.Context, arg GetBetw...
constant getBetweenPricesTable (line 80) | getBetweenPricesTable = `-- name: GetBetweenPricesTable :many
type GetBetweenPricesTableParams (line 86) | type GetBetweenPricesTableParams struct
method GetBetweenPricesTable (line 91) | func (q *Queries) GetBetweenPricesTable(ctx context.Context, arg GetBetw...
constant getBetweenPricesTableAlias (line 114) | getBetweenPricesTableAlias = `-- name: GetBetweenPricesTableAlias :many
type GetBetweenPricesTableAliasParams (line 120) | type GetBetweenPricesTableAliasParams struct
method GetBetweenPricesTableAlias (line 125) | func (q *Queries) GetBetweenPricesTableAlias(ctx context.Context, arg Ge...
FILE: internal/endtoend/testdata/between_args/mysql/schema.sql
type products (line 1) | CREATE TABLE products (
FILE: internal/endtoend/testdata/between_args/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/between_args/sqlite/go/models.go
type Product (line 7) | type Product struct
FILE: internal/endtoend/testdata/between_args/sqlite/go/query.sql.go
constant getBetweenPrices (line 12) | getBetweenPrices = `-- name: GetBetweenPrices :many
type GetBetweenPricesParams (line 18) | type GetBetweenPricesParams struct
method GetBetweenPrices (line 23) | func (q *Queries) GetBetweenPrices(ctx context.Context, arg GetBetweenPr...
constant getBetweenPricesTable (line 46) | getBetweenPricesTable = `-- name: GetBetweenPricesTable :many
type GetBetweenPricesTableParams (line 52) | type GetBetweenPricesTableParams struct
method GetBetweenPricesTable (line 57) | func (q *Queries) GetBetweenPricesTable(ctx context.Context, arg GetBetw...
constant getBetweenPricesTableAlias (line 80) | getBetweenPricesTableAlias = `-- name: GetBetweenPricesTableAlias :many
type GetBetweenPricesTableAliasParams (line 86) | type GetBetweenPricesTableAliasParams struct
method GetBetweenPricesTableAlias (line 91) | func (q *Queries) GetBetweenPricesTableAlias(ctx context.Context, arg Ge...
FILE: internal/endtoend/testdata/between_args/sqlite/schema.sql
type products (line 1) | CREATE TABLE products (
FILE: internal/endtoend/testdata/bit_string/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/bit_string/pgx/v4/go/models.go
type TestTable (line 11) | type TestTable struct
FILE: internal/endtoend/testdata/bit_string/pgx/v4/go/query.sql.go
constant selectTest (line 12) | selectTest = `-- name: SelectTest :many
method SelectTest (line 17) | func (q *Queries) SelectTest(ctx context.Context) ([]TestTable, error) {
FILE: internal/endtoend/testdata/bit_string/pgx/v4/schema.sql
type test_table (line 1) | CREATE TABLE test_table
FILE: internal/endtoend/testdata/bit_string/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/bit_string/pgx/v5/go/models.go
type TestTable (line 11) | type TestTable struct
FILE: internal/endtoend/testdata/bit_string/pgx/v5/go/query.sql.go
constant selectTest (line 12) | selectTest = `-- name: SelectTest :many
method SelectTest (line 17) | func (q *Queries) SelectTest(ctx context.Context) ([]TestTable, error) {
FILE: internal/endtoend/testdata/bit_string/pgx/v5/schema.sql
type test_table (line 1) | CREATE TABLE test_table
FILE: internal/endtoend/testdata/build_tags/postgresql/stdlib/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 21) | func New(db DBTX) *Queries {
type Queries (line 25) | type Queries struct
method WithTx (line 29) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/build_tags/postgresql/stdlib/go/models.go
type Author (line 13) | type Author struct
FILE: internal/endtoend/testdata/build_tags/postgresql/stdlib/go/querier.go
type Querier (line 13) | type Querier interface
FILE: internal/endtoend/testdata/build_tags/postgresql/stdlib/go/query.sql.go
constant createAuthor (line 15) | createAuthor = `-- name: CreateAuthor :one
type CreateAuthorParams (line 24) | type CreateAuthorParams struct
method CreateAuthor (line 29) | func (q *Queries) CreateAuthor(ctx context.Context, arg CreateAuthorPara...
constant deleteAuthor (line 36) | deleteAuthor = `-- name: DeleteAuthor :exec
method DeleteAuthor (line 41) | func (q *Queries) DeleteAuthor(ctx context.Context, id int64) error {
constant getAuthor (line 46) | getAuthor = `-- name: GetAuthor :one
method GetAuthor (line 51) | func (q *Queries) GetAuthor(ctx context.Context, id int64) (Author, erro...
constant listAuthors (line 58) | listAuthors = `-- name: ListAuthors :many
method ListAuthors (line 63) | func (q *Queries) ListAuthors(ctx context.Context) ([]Author, error) {
FILE: internal/endtoend/testdata/build_tags/postgresql/stdlib/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/builtins/postgresql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/builtins/postgresql/go/query.sql.go
constant abs (line 12) | abs = `-- name: Abs :one
method Abs (line 16) | func (q *Queries) Abs(ctx context.Context) (int64, error) {
constant cbrt (line 23) | cbrt = `-- name: Cbrt :one
method Cbrt (line 27) | func (q *Queries) Cbrt(ctx context.Context) (float64, error) {
constant ceil (line 34) | ceil = `-- name: Ceil :one
method Ceil (line 38) | func (q *Queries) Ceil(ctx context.Context) (float64, error) {
constant ceiling (line 45) | ceiling = `-- name: Ceiling :one
method Ceiling (line 49) | func (q *Queries) Ceiling(ctx context.Context) (float64, error) {
constant degrees (line 56) | degrees = `-- name: Degrees :one
method Degrees (line 60) | func (q *Queries) Degrees(ctx context.Context) (float64, error) {
constant div (line 67) | div = `-- name: Div :one
method Div (line 71) | func (q *Queries) Div(ctx context.Context) (string, error) {
constant exp (line 78) | exp = `-- name: Exp :one
method Exp (line 82) | func (q *Queries) Exp(ctx context.Context) (float64, error) {
constant floor (line 89) | floor = `-- name: Floor :one
method Floor (line 93) | func (q *Queries) Floor(ctx context.Context) (float64, error) {
constant ln (line 100) | ln = `-- name: Ln :one
method Ln (line 104) | func (q *Queries) Ln(ctx context.Context) (float64, error) {
constant log (line 111) | log = `-- name: Log :one
method Log (line 115) | func (q *Queries) Log(ctx context.Context) (float64, error) {
constant logs (line 122) | logs = `-- name: Logs :one
method Logs (line 126) | func (q *Queries) Logs(ctx context.Context) (string, error) {
constant mod (line 133) | mod = `-- name: Mod :one
method Mod (line 137) | func (q *Queries) Mod(ctx context.Context) (int64, error) {
constant pi (line 144) | pi = `-- name: Pi :one
method Pi (line 148) | func (q *Queries) Pi(ctx context.Context) (float64, error) {
constant power (line 155) | power = `-- name: Power :one
method Power (line 159) | func (q *Queries) Power(ctx context.Context) (float64, error) {
constant radians (line 166) | radians = `-- name: Radians :one
method Radians (line 170) | func (q *Queries) Radians(ctx context.Context) (float64, error) {
constant round (line 177) | round = `-- name: Round :one
method Round (line 181) | func (q *Queries) Round(ctx context.Context) (float64, error) {
constant rounds (line 188) | rounds = `-- name: Rounds :one
method Rounds (line 192) | func (q *Queries) Rounds(ctx context.Context) (string, error) {
constant scale (line 199) | scale = `-- name: Scale :one
method Scale (line 203) | func (q *Queries) Scale(ctx context.Context) (int32, error) {
constant sign (line 210) | sign = `-- name: Sign :one
method Sign (line 214) | func (q *Queries) Sign(ctx context.Context) (float64, error) {
constant sqrt (line 221) | sqrt = `-- name: Sqrt :one
method Sqrt (line 225) | func (q *Queries) Sqrt(ctx context.Context) (float64, error) {
constant trunc (line 232) | trunc = `-- name: Trunc :one
method Trunc (line 236) | func (q *Queries) Trunc(ctx context.Context) (float64, error) {
constant truncs (line 243) | truncs = `-- name: Truncs :one
method Truncs (line 247) | func (q *Queries) Truncs(ctx context.Context) (string, error) {
constant widthBucketNumerics (line 254) | widthBucketNumerics = `-- name: WidthBucketNumerics :one
method WidthBucketNumerics (line 258) | func (q *Queries) WidthBucketNumerics(ctx context.Context) (int32, error) {
constant widthBucketTimestamps (line 265) | widthBucketTimestamps = `-- name: WidthBucketTimestamps :one
method WidthBucketTimestamps (line 269) | func (q *Queries) WidthBucketTimestamps(ctx context.Context) (int32, err...
FILE: internal/endtoend/testdata/builtins/sqlite/go/aggfunc.sql.go
constant getAvg (line 13) | getAvg = `-- name: GetAvg :one
method GetAvg (line 17) | func (q *Queries) GetAvg(ctx context.Context) (sql.NullFloat64, error) {
constant getCount (line 24) | getCount = `-- name: GetCount :one
method GetCount (line 28) | func (q *Queries) GetCount(ctx context.Context) (int64, error) {
constant getCountId (line 35) | getCountId = `-- name: GetCountId :one
method GetCountId (line 39) | func (q *Queries) GetCountId(ctx context.Context) (int64, error) {
constant getGroupConcatInt (line 46) | getGroupConcatInt = `-- name: GetGroupConcatInt :one
method GetGroupConcatInt (line 50) | func (q *Queries) GetGroupConcatInt(ctx context.Context) (string, error) {
constant getGroupConcatInt2 (line 57) | getGroupConcatInt2 = `-- name: GetGroupConcatInt2 :one
method GetGroupConcatInt2 (line 61) | func (q *Queries) GetGroupConcatInt2(ctx context.Context) (string, error) {
constant getGroupConcatText (line 68) | getGroupConcatText = `-- name: GetGroupConcatText :one
method GetGroupConcatText (line 72) | func (q *Queries) GetGroupConcatText(ctx context.Context) (string, error) {
constant getGroupConcatText2 (line 79) | getGroupConcatText2 = `-- name: GetGroupConcatText2 :one
method GetGroupConcatText2 (line 83) | func (q *Queries) GetGroupConcatText2(ctx context.Context) (string, erro...
constant getMaxInt (line 90) | getMaxInt = `-- name: GetMaxInt :one
method GetMaxInt (line 94) | func (q *Queries) GetMaxInt(ctx context.Context) (interface{}, error) {
constant getMaxText (line 101) | getMaxText = `-- name: GetMaxText :one
method GetMaxText (line 105) | func (q *Queries) GetMaxText(ctx context.Context) (interface{}, error) {
constant getMinInt (line 112) | getMinInt = `-- name: GetMinInt :one
method GetMinInt (line 116) | func (q *Queries) GetMinInt(ctx context.Context) (interface{}, error) {
constant getMinText (line 123) | getMinText = `-- name: GetMinText :one
method GetMinText (line 127) | func (q *Queries) GetMinText(ctx context.Context) (interface{}, error) {
constant getSumInt (line 134) | getSumInt = `-- name: GetSumInt :one
method GetSumInt (line 138) | func (q *Queries) GetSumInt(ctx context.Context) (sql.NullFloat64, error) {
constant getSumText (line 145) | getSumText = `-- name: GetSumText :one
method GetSumText (line 149) | func (q *Queries) GetSumText(ctx context.Context) (sql.NullFloat64, erro...
constant getTotalInt (line 156) | getTotalInt = `-- name: GetTotalInt :one
method GetTotalInt (line 160) | func (q *Queries) GetTotalInt(ctx context.Context) (float64, error) {
FILE: internal/endtoend/testdata/builtins/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/builtins/sqlite/go/mathfunc.sql.go
constant getAcos (line 12) | getAcos = `-- name: GetAcos :one
method GetAcos (line 16) | func (q *Queries) GetAcos(ctx context.Context) (float64, error) {
constant getAcosh (line 23) | getAcosh = `-- name: GetAcosh :one
method GetAcosh (line 27) | func (q *Queries) GetAcosh(ctx context.Context) (float64, error) {
constant getAsin (line 34) | getAsin = `-- name: GetAsin :one
method GetAsin (line 38) | func (q *Queries) GetAsin(ctx context.Context) (float64, error) {
constant getAsinh (line 45) | getAsinh = `-- name: GetAsinh :one
method GetAsinh (line 49) | func (q *Queries) GetAsinh(ctx context.Context) (float64, error) {
constant getAtan (line 56) | getAtan = `-- name: GetAtan :one
method GetAtan (line 60) | func (q *Queries) GetAtan(ctx context.Context) (float64, error) {
constant getAtan2 (line 67) | getAtan2 = `-- name: GetAtan2 :one
method GetAtan2 (line 71) | func (q *Queries) GetAtan2(ctx context.Context) (float64, error) {
constant getAtanh (line 78) | getAtanh = `-- name: GetAtanh :one
method GetAtanh (line 82) | func (q *Queries) GetAtanh(ctx context.Context) (float64, error) {
constant getCeil (line 89) | getCeil = `-- name: GetCeil :one
method GetCeil (line 93) | func (q *Queries) GetCeil(ctx context.Context) (int64, error) {
constant getCeilin (line 100) | getCeilin = `-- name: GetCeilin :one
method GetCeilin (line 104) | func (q *Queries) GetCeilin(ctx context.Context) (int64, error) {
constant getCos (line 111) | getCos = `-- name: GetCos :one
method GetCos (line 115) | func (q *Queries) GetCos(ctx context.Context) (float64, error) {
constant getCosh (line 122) | getCosh = `-- name: GetCosh :one
method GetCosh (line 126) | func (q *Queries) GetCosh(ctx context.Context) (float64, error) {
constant getDegrees (line 133) | getDegrees = `-- name: GetDegrees :one
method GetDegrees (line 137) | func (q *Queries) GetDegrees(ctx context.Context) (float64, error) {
constant getExp (line 144) | getExp = `-- name: GetExp :one
method GetExp (line 148) | func (q *Queries) GetExp(ctx context.Context) (float64, error) {
constant getFloor (line 155) | getFloor = `-- name: GetFloor :one
method GetFloor (line 159) | func (q *Queries) GetFloor(ctx context.Context) (int64, error) {
constant getLn (line 166) | getLn = `-- name: GetLn :one
method GetLn (line 170) | func (q *Queries) GetLn(ctx context.Context) (float64, error) {
constant getLog (line 177) | getLog = `-- name: GetLog :one
method GetLog (line 181) | func (q *Queries) GetLog(ctx context.Context) (float64, error) {
constant getLog10 (line 188) | getLog10 = `-- name: GetLog10 :one
method GetLog10 (line 192) | func (q *Queries) GetLog10(ctx context.Context) (float64, error) {
constant getLog2 (line 199) | getLog2 = `-- name: GetLog2 :one
method GetLog2 (line 203) | func (q *Queries) GetLog2(ctx context.Context) (float64, error) {
constant getLogBase (line 210) | getLogBase = `-- name: GetLogBase :one
method GetLogBase (line 214) | func (q *Queries) GetLogBase(ctx context.Context) (float64, error) {
constant getMod (line 221) | getMod = `-- name: GetMod :one
method GetMod (line 225) | func (q *Queries) GetMod(ctx context.Context) (float64, error) {
constant getPi (line 232) | getPi = `-- name: GetPi :one
method GetPi (line 236) | func (q *Queries) GetPi(ctx context.Context) (float64, error) {
constant getPow (line 243) | getPow = `-- name: GetPow :one
method GetPow (line 247) | func (q *Queries) GetPow(ctx context.Context) (float64, error) {
constant getPower (line 254) | getPower = `-- name: GetPower :one
method GetPower (line 258) | func (q *Queries) GetPower(ctx context.Context) (float64, error) {
constant getRadians (line 265) | getRadians = `-- name: GetRadians :one
method GetRadians (line 269) | func (q *Queries) GetRadians(ctx context.Context) (float64, error) {
constant getSin (line 276) | getSin = `-- name: GetSin :one
method GetSin (line 280) | func (q *Queries) GetSin(ctx context.Context) (float64, error) {
constant getSinh (line 287) | getSinh = `-- name: GetSinh :one
method GetSinh (line 291) | func (q *Queries) GetSinh(ctx context.Context) (float64, error) {
constant getSqrt (line 298) | getSqrt = `-- name: GetSqrt :one
method GetSqrt (line 302) | func (q *Queries) GetSqrt(ctx context.Context) (float64, error) {
constant getTan (line 309) | getTan = `-- name: GetTan :one
method GetTan (line 313) | func (q *Queries) GetTan(ctx context.Context) (float64, error) {
constant getTrunc (line 320) | getTrunc = `-- name: GetTrunc :one
method GetTrunc (line 324) | func (q *Queries) GetTrunc(ctx context.Context) (int64, error) {
FILE: internal/endtoend/testdata/builtins/sqlite/go/models.go
type Test (line 7) | type Test struct
FILE: internal/endtoend/testdata/builtins/sqlite/go/scalarfunc.sql.go
constant getAbs (line 13) | getAbs = `-- name: GetAbs :one
method GetAbs (line 17) | func (q *Queries) GetAbs(ctx context.Context) (float64, error) {
constant getChanges (line 24) | getChanges = `-- name: GetChanges :one
method GetChanges (line 28) | func (q *Queries) GetChanges(ctx context.Context) (int64, error) {
constant getChar1 (line 35) | getChar1 = `-- name: GetChar1 :one
method GetChar1 (line 39) | func (q *Queries) GetChar1(ctx context.Context) (string, error) {
constant getChar3 (line 46) | getChar3 = `-- name: GetChar3 :one
method GetChar3 (line 50) | func (q *Queries) GetChar3(ctx context.Context) (string, error) {
constant getCoalesce (line 57) | getCoalesce = `-- name: GetCoalesce :one
method GetCoalesce (line 61) | func (q *Queries) GetCoalesce(ctx context.Context) (interface{}, error) {
constant getFormat (line 68) | getFormat = `-- name: GetFormat :one
method GetFormat (line 72) | func (q *Queries) GetFormat(ctx context.Context) (sql.NullString, error) {
constant getGlob (line 79) | getGlob = `-- name: GetGlob :one
method GetGlob (line 83) | func (q *Queries) GetGlob(ctx context.Context) (int64, error) {
constant getHex (line 90) | getHex = `-- name: GetHex :one
method GetHex (line 94) | func (q *Queries) GetHex(ctx context.Context) (string, error) {
constant getIfnull (line 101) | getIfnull = `-- name: GetIfnull :one
method GetIfnull (line 105) | func (q *Queries) GetIfnull(ctx context.Context) (interface{}, error) {
constant getIif (line 112) | getIif = `-- name: GetIif :one
method GetIif (line 116) | func (q *Queries) GetIif(ctx context.Context) (interface{}, error) {
constant getInstr (line 123) | getInstr = `-- name: GetInstr :one
method GetInstr (line 127) | func (q *Queries) GetInstr(ctx context.Context) (sql.NullInt64, error) {
constant getLastInsertRowID (line 134) | getLastInsertRowID = `-- name: GetLastInsertRowID :one
method GetLastInsertRowID (line 138) | func (q *Queries) GetLastInsertRowID(ctx context.Context) (int64, error) {
constant getLength (line 145) | getLength = `-- name: GetLength :one
method GetLength (line 149) | func (q *Queries) GetLength(ctx context.Context) (sql.NullInt64, error) {
constant getLike2 (line 156) | getLike2 = `-- name: GetLike2 :one
method GetLike2 (line 160) | func (q *Queries) GetLike2(ctx context.Context) (int64, error) {
constant getLike3 (line 167) | getLike3 = `-- name: GetLike3 :one
method GetLike3 (line 171) | func (q *Queries) GetLike3(ctx context.Context) (int64, error) {
constant getLikelihood (line 178) | getLikelihood = `-- name: GetLikelihood :one
method GetLikelihood (line 182) | func (q *Queries) GetLikelihood(ctx context.Context) (interface{}, error) {
constant getLikely (line 189) | getLikely = `-- name: GetLikely :one
method GetLikely (line 193) | func (q *Queries) GetLikely(ctx context.Context) (interface{}, error) {
constant getLower (line 200) | getLower = `-- name: GetLower :one
method GetLower (line 204) | func (q *Queries) GetLower(ctx context.Context) (string, error) {
constant getLtrim (line 211) | getLtrim = `-- name: GetLtrim :one
method GetLtrim (line 215) | func (q *Queries) GetLtrim(ctx context.Context) (string, error) {
constant getLtrim2 (line 222) | getLtrim2 = `-- name: GetLtrim2 :one
method GetLtrim2 (line 226) | func (q *Queries) GetLtrim2(ctx context.Context) (string, error) {
constant getMax3 (line 233) | getMax3 = `-- name: GetMax3 :one
method GetMax3 (line 237) | func (q *Queries) GetMax3(ctx context.Context) (interface{}, error) {
constant getMin3 (line 244) | getMin3 = `-- name: GetMin3 :one
method GetMin3 (line 248) | func (q *Queries) GetMin3(ctx context.Context) (interface{}, error) {
constant getNullif (line 255) | getNullif = `-- name: GetNullif :one
method GetNullif (line 259) | func (q *Queries) GetNullif(ctx context.Context) (interface{}, error) {
constant getPrintf (line 266) | getPrintf = `-- name: GetPrintf :one
method GetPrintf (line 270) | func (q *Queries) GetPrintf(ctx context.Context) (sql.NullString, error) {
constant getQuote (line 277) | getQuote = `-- name: GetQuote :one
method GetQuote (line 281) | func (q *Queries) GetQuote(ctx context.Context) (string, error) {
constant getRandom (line 288) | getRandom = `-- name: GetRandom :one
method GetRandom (line 292) | func (q *Queries) GetRandom(ctx context.Context) (interface{}, error) {
constant getRandomBlob (line 299) | getRandomBlob = `-- name: GetRandomBlob :one
method GetRandomBlob (line 303) | func (q *Queries) GetRandomBlob(ctx context.Context) (interface{}, error) {
constant getReplace (line 310) | getReplace = `-- name: GetReplace :one
method GetReplace (line 314) | func (q *Queries) GetReplace(ctx context.Context) (string, error) {
constant getRound (line 321) | getRound = `-- name: GetRound :one
method GetRound (line 325) | func (q *Queries) GetRound(ctx context.Context) (float64, error) {
constant getRound2 (line 332) | getRound2 = `-- name: GetRound2 :one
method GetRound2 (line 336) | func (q *Queries) GetRound2(ctx context.Context) (float64, error) {
constant getRtrim (line 343) | getRtrim = `-- name: GetRtrim :one
method GetRtrim (line 347) | func (q *Queries) GetRtrim(ctx context.Context) (string, error) {
constant getRtrim2 (line 354) | getRtrim2 = `-- name: GetRtrim2 :one
method GetRtrim2 (line 358) | func (q *Queries) GetRtrim2(ctx context.Context) (string, error) {
constant getSQLiteCompileOptionGet (line 365) | getSQLiteCompileOptionGet = `-- name: GetSQLiteCompileOptionGet :one
method GetSQLiteCompileOptionGet (line 369) | func (q *Queries) GetSQLiteCompileOptionGet(ctx context.Context) (sql.Nu...
constant getSQLiteCompileOptionUsed (line 376) | getSQLiteCompileOptionUsed = `-- name: GetSQLiteCompileOptionUsed :one
method GetSQLiteCompileOptionUsed (line 380) | func (q *Queries) GetSQLiteCompileOptionUsed(ctx context.Context) (int64...
constant getSQLiteSourceID (line 387) | getSQLiteSourceID = `-- name: GetSQLiteSourceID :one
method GetSQLiteSourceID (line 391) | func (q *Queries) GetSQLiteSourceID(ctx context.Context) (string, error) {
constant getSQLiteVersion (line 398) | getSQLiteVersion = `-- name: GetSQLiteVersion :one
method GetSQLiteVersion (line 402) | func (q *Queries) GetSQLiteVersion(ctx context.Context) (string, error) {
constant getSign (line 409) | getSign = `-- name: GetSign :one
method GetSign (line 413) | func (q *Queries) GetSign(ctx context.Context) (sql.NullInt64, error) {
constant getSoundex (line 420) | getSoundex = `-- name: GetSoundex :one
method GetSoundex (line 424) | func (q *Queries) GetSoundex(ctx context.Context) (string, error) {
constant getSubstr2 (line 431) | getSubstr2 = `-- name: GetSubstr2 :one
method GetSubstr2 (line 435) | func (q *Queries) GetSubstr2(ctx context.Context) (string, error) {
constant getSubstr3 (line 442) | getSubstr3 = `-- name: GetSubstr3 :one
method GetSubstr3 (line 446) | func (q *Queries) GetSubstr3(ctx context.Context) (string, error) {
constant getSubstring2 (line 453) | getSubstring2 = `-- name: GetSubstring2 :one
method GetSubstring2 (line 457) | func (q *Queries) GetSubstring2(ctx context.Context) (string, error) {
constant getSusbstring3 (line 464) | getSusbstring3 = `-- name: GetSusbstring3 :one
method GetSusbstring3 (line 468) | func (q *Queries) GetSusbstring3(ctx context.Context) (string, error) {
constant getTotalChanges (line 475) | getTotalChanges = `-- name: GetTotalChanges :one
method GetTotalChanges (line 479) | func (q *Queries) GetTotalChanges(ctx context.Context) (int64, error) {
constant getTrim (line 486) | getTrim = `-- name: GetTrim :one
method GetTrim (line 490) | func (q *Queries) GetTrim(ctx context.Context) (string, error) {
constant getTrim2 (line 497) | getTrim2 = `-- name: GetTrim2 :one
method GetTrim2 (line 501) | func (q *Queries) GetTrim2(ctx context.Context) (string, error) {
constant getTypeof (line 508) | getTypeof = `-- name: GetTypeof :one
method GetTypeof (line 512) | func (q *Queries) GetTypeof(ctx context.Context) (string, error) {
constant getUnicode (line 519) | getUnicode = `-- name: GetUnicode :one
method GetUnicode (line 523) | func (q *Queries) GetUnicode(ctx context.Context) (int64, error) {
constant getUnlikely (line 530) | getUnlikely = `-- name: GetUnlikely :one
method GetUnlikely (line 534) | func (q *Queries) GetUnlikely(ctx context.Context) (interface{}, error) {
constant getUpper (line 541) | getUpper = `-- name: GetUpper :one
method GetUpper (line 545) | func (q *Queries) GetUpper(ctx context.Context) (string, error) {
constant getZeroblob (line 552) | getZeroblob = `-- name: GetZeroblob :one
method GetZeroblob (line 556) | func (q *Queries) GetZeroblob(ctx context.Context) ([]byte, error) {
FILE: internal/endtoend/testdata/builtins/sqlite/schema.sql
type test (line 1) | CREATE TABLE test (
FILE: internal/endtoend/testdata/case_named_params/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_named_params/mysql/go/models.go
type Author (line 11) | type Author struct
FILE: internal/endtoend/testdata/case_named_params/mysql/go/query.sql.go
constant listAuthors (line 13) | listAuthors = `-- name: ListAuthors :one
type ListAuthorsParams (line 21) | type ListAuthorsParams struct
method ListAuthors (line 26) | func (q *Queries) ListAuthors(ctx context.Context, arg ListAuthorsParams...
FILE: internal/endtoend/testdata/case_named_params/mysql/schema.sql
type authors (line 3) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/case_named_params/postgresql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_named_params/postgresql/go/models.go
type Author (line 11) | type Author struct
FILE: internal/endtoend/testdata/case_named_params/postgresql/go/query.sql.go
constant listAuthors (line 12) | listAuthors = `-- name: ListAuthors :one
type ListAuthorsParams (line 20) | type ListAuthorsParams struct
method ListAuthors (line 25) | func (q *Queries) ListAuthors(ctx context.Context, arg ListAuthorsParams...
FILE: internal/endtoend/testdata/case_named_params/postgresql/schema.sql
type authors (line 3) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/case_named_params/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_named_params/sqlite/go/models.go
type Author (line 11) | type Author struct
FILE: internal/endtoend/testdata/case_named_params/sqlite/go/query.sql.go
constant listAuthors (line 12) | listAuthors = `-- name: ListAuthors :one
type ListAuthorsParams (line 20) | type ListAuthorsParams struct
method ListAuthors (line 25) | func (q *Queries) ListAuthors(ctx context.Context, arg ListAuthorsParams...
FILE: internal/endtoend/testdata/case_named_params/sqlite/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/case_sensitive/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_sensitive/sqlite/go/models.go
type Contact (line 11) | type Contact struct
FILE: internal/endtoend/testdata/case_sensitive/sqlite/go/query.sql.go
constant insertContact (line 13) | insertContact = `-- name: InsertContact :exec
type InsertContactParams (line 21) | type InsertContactParams struct
method InsertContact (line 26) | func (q *Queries) InsertContact(ctx context.Context, arg InsertContactPa...
FILE: internal/endtoend/testdata/case_sensitive/sqlite/schema.sql
type contacts (line 1) | CREATE TABLE contacts (
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v4/go/models.go
type Foo (line 7) | type Foo struct
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v4/go/query.sql.go
constant caseStatementBoolean (line 12) | caseStatementBoolean = `-- name: CaseStatementBoolean :many
method CaseStatementBoolean (line 20) | func (q *Queries) CaseStatementBoolean(ctx context.Context, id string) (...
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null)
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v5/go/models.go
type Foo (line 7) | type Foo struct
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v5/go/query.sql.go
constant caseStatementBoolean (line 12) | caseStatementBoolean = `-- name: CaseStatementBoolean :many
method CaseStatementBoolean (line 20) | func (q *Queries) CaseStatementBoolean(ctx context.Context, id string) (...
FILE: internal/endtoend/testdata/case_stmt_bool/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null)
FILE: internal/endtoend/testdata/case_stmt_bool/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_stmt_bool/stdlib/go/models.go
type Foo (line 7) | type Foo struct
FILE: internal/endtoend/testdata/case_stmt_bool/stdlib/go/query.sql.go
constant caseStatementBoolean (line 12) | caseStatementBoolean = `-- name: CaseStatementBoolean :many
method CaseStatementBoolean (line 20) | func (q *Queries) CaseStatementBoolean(ctx context.Context, id string) (...
FILE: internal/endtoend/testdata/case_stmt_bool/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null)
FILE: internal/endtoend/testdata/case_text/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/case_text/pgx/v4/go/models.go
type Foo (line 7) | type Foo struct
FILE: internal/endtoend/testdata/case_text/pgx/v4/go/query.sql.go
constant caseStatementText (line 12) | caseStatementText = `-- name: CaseStatementText :many
method CaseStatementText (line 20) | func (q *Queries) CaseStatementText(ctx context.Context, id string) ([]s...
FILE: internal/endtoend/testdata/case_text/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null)
FILE: internal/endtoend/testdata/case_text/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/case_text/pgx/v5/go/models.go
type Foo (line 7) | type Foo struct
FILE: internal/endtoend/testdata/case_text/pgx/v5/go/query.sql.go
constant caseStatementText (line 12) | caseStatementText = `-- name: CaseStatementText :many
method CaseStatementText (line 20) | func (q *Queries) CaseStatementText(ctx context.Context, id string) ([]s...
FILE: internal/endtoend/testdata/case_text/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null)
FILE: internal/endtoend/testdata/case_text/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_text/stdlib/go/models.go
type Foo (line 7) | type Foo struct
FILE: internal/endtoend/testdata/case_text/stdlib/go/query.sql.go
constant caseStatementText (line 12) | caseStatementText = `-- name: CaseStatementText :many
method CaseStatementText (line 20) | func (q *Queries) CaseStatementText(ctx context.Context, id string) ([]s...
FILE: internal/endtoend/testdata/case_text/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (id text not null)
FILE: internal/endtoend/testdata/case_value_param/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/case_value_param/mysql/go/models.go
type Testing (line 11) | type Testing struct
FILE: internal/endtoend/testdata/case_value_param/mysql/go/query.sql.go
constant update (line 13) | update = `-- name: Update :exec
method Update (line 18) | func (q *Queries) Update(ctx context.Context, value sql.NullString) error {
FILE: internal/endtoend/testdata/case_value_param/mysql/schema.sql
type testing (line 1) | CREATE TABLE testing (
FILE: internal/endtoend/testdata/case_value_param/postgresql/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/case_value_param/postgresql/go/models.go
type Testing (line 11) | type Testing struct
FILE: internal/endtoend/testdata/case_value_param/postgresql/go/query.sql.go
constant update (line 14) | update = `-- name: Update :exec
method Update (line 19) | func (q *Queries) Update(ctx context.Context, value pgtype.Text) error {
FILE: internal/endtoend/testdata/case_value_param/postgresql/schema.sql
type testing (line 1) | CREATE TABLE testing (
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v4/go/query.sql.go
constant castCoalesce (line 12) | castCoalesce = `-- name: CastCoalesce :many
method CastCoalesce (line 17) | func (q *Queries) CastCoalesce(ctx context.Context) ([]string, error) {
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v5/go/query.sql.go
constant castCoalesce (line 12) | castCoalesce = `-- name: CastCoalesce :many
method CastCoalesce (line 17) | func (q *Queries) CastCoalesce(ctx context.Context) ([]string, error) {
FILE: internal/endtoend/testdata/cast_coalesce/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/cast_coalesce/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_coalesce/stdlib/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/cast_coalesce/stdlib/go/query.sql.go
constant castCoalesce (line 12) | castCoalesce = `-- name: CastCoalesce :many
method CastCoalesce (line 17) | func (q *Queries) CastCoalesce(ctx context.Context) ([]string, error) {
FILE: internal/endtoend/testdata/cast_coalesce/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/cast_null/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_null/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/cast_null/pgx/v4/go/query.sql.go
constant listNullable (line 13) | listNullable = `-- name: ListNullable :many
type ListNullableRow (line 22) | type ListNullableRow struct
method ListNullable (line 29) | func (q *Queries) ListNullable(ctx context.Context) ([]ListNullableRow, ...
FILE: internal/endtoend/testdata/cast_null/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/cast_null/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_null/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/cast_null/pgx/v5/go/query.sql.go
constant listNullable (line 14) | listNullable = `-- name: ListNullable :many
type ListNullableRow (line 23) | type ListNullableRow struct
method ListNullable (line 30) | func (q *Queries) ListNullable(ctx context.Context) ([]ListNullableRow, ...
FILE: internal/endtoend/testdata/cast_null/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/cast_null/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_null/stdlib/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/cast_null/stdlib/go/query.sql.go
constant listNullable (line 13) | listNullable = `-- name: ListNullable :many
type ListNullableRow (line 22) | type ListNullableRow struct
method ListNullable (line 29) | func (q *Queries) ListNullable(ctx context.Context) ([]ListNullableRow, ...
FILE: internal/endtoend/testdata/cast_null/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/cast_param/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/cast_param/sqlite/go/models.go
type MyTable (line 11) | type MyTable struct
FILE: internal/endtoend/testdata/cast_param/sqlite/go/query.sql.go
constant getData (line 12) | getData = `-- name: GetData :many
method GetData (line 18) | func (q *Queries) GetData(ctx context.Context, allowInvalid bool) ([]MyT...
FILE: internal/endtoend/testdata/cast_param/sqlite/schema.sql
type my_table (line 1) | create table my_table
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v4/go/models.go
type TestTable (line 11) | type TestTable struct
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v4/go/query.sql.go
constant selectTest (line 12) | selectTest = `-- name: SelectTest :many
method SelectTest (line 17) | func (q *Queries) SelectTest(ctx context.Context) ([]TestTable, error) {
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v4/schema.sql
type test_table (line 1) | CREATE TABLE test_table
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v5/go/models.go
type TestTable (line 11) | type TestTable struct
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v5/go/query.sql.go
constant selectTest (line 12) | selectTest = `-- name: SelectTest :many
method SelectTest (line 17) | func (q *Queries) SelectTest(ctx context.Context) ([]TestTable, error) {
FILE: internal/endtoend/testdata/cid_oid_tid_xid/pgx/v5/schema.sql
type test_table (line 1) | CREATE TABLE test_table
FILE: internal/endtoend/testdata/citext/pgx/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/citext/pgx/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/citext/pgx/go/query.sql.go
constant getCitexts (line 12) | getCitexts = `-- name: GetCitexts :many
method GetCitexts (line 17) | func (q *Queries) GetCitexts(ctx context.Context) ([]Foo, error) {
FILE: internal/endtoend/testdata/citext/pgx/schema.sql
type foo (line 3) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/citext/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/citext/stdlib/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/citext/stdlib/go/query.sql.go
constant getCitexts (line 12) | getCitexts = `-- name: GetCitexts :many
method GetCitexts (line 17) | func (q *Queries) GetCitexts(ctx context.Context) ([]Foo, error) {
FILE: internal/endtoend/testdata/citext/stdlib/schema.sql
type foo (line 3) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce/mysql/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce/mysql/go/query.sql.go
constant coalesce (line 13) | coalesce = `-- name: Coalesce :many
method Coalesce (line 18) | func (q *Queries) Coalesce(ctx context.Context) ([]string, error) {
constant coalesceColumns (line 41) | coalesceColumns = `-- name: CoalesceColumns :many
type CoalesceColumnsRow (line 46) | type CoalesceColumnsRow struct
method CoalesceColumns (line 52) | func (q *Queries) CoalesceColumns(ctx context.Context) ([]CoalesceColumn...
FILE: internal/endtoend/testdata/coalesce/mysql/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text, bat text not null)
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v4/go/query.sql.go
constant coalesceNumeric (line 13) | coalesceNumeric = `-- name: CoalesceNumeric :many
method CoalesceNumeric (line 18) | func (q *Queries) CoalesceNumeric(ctx context.Context) ([]int64, error) {
constant coalesceNumericColumns (line 38) | coalesceNumericColumns = `-- name: CoalesceNumericColumns :many
type CoalesceNumericColumnsRow (line 43) | type CoalesceNumericColumnsRow struct
method CoalesceNumericColumns (line 49) | func (q *Queries) CoalesceNumericColumns(ctx context.Context) ([]Coalesc...
constant coalesceNumericNull (line 69) | coalesceNumericNull = `-- name: CoalesceNumericNull :many
type CoalesceNumericNullRow (line 74) | type CoalesceNumericNullRow struct
method CoalesceNumericNull (line 79) | func (q *Queries) CoalesceNumericNull(ctx context.Context) ([]CoalesceNu...
constant coalesceString (line 99) | coalesceString = `-- name: CoalesceString :many
method CoalesceString (line 104) | func (q *Queries) CoalesceString(ctx context.Context) ([]string, error) {
constant coalesceStringColumns (line 124) | coalesceStringColumns = `-- name: CoalesceStringColumns :many
type CoalesceStringColumnsRow (line 129) | type CoalesceStringColumnsRow struct
method CoalesceStringColumns (line 135) | func (q *Queries) CoalesceStringColumns(ctx context.Context) ([]Coalesce...
constant coalesceStringNull (line 155) | coalesceStringNull = `-- name: CoalesceStringNull :many
type CoalesceStringNullRow (line 160) | type CoalesceStringNullRow struct
method CoalesceStringNull (line 165) | func (q *Queries) CoalesceStringNull(ctx context.Context) ([]CoalesceStr...
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v5/go/query.sql.go
constant coalesceNumeric (line 14) | coalesceNumeric = `-- name: CoalesceNumeric :many
method CoalesceNumeric (line 19) | func (q *Queries) CoalesceNumeric(ctx context.Context) ([]int64, error) {
constant coalesceNumericColumns (line 39) | coalesceNumericColumns = `-- name: CoalesceNumericColumns :many
type CoalesceNumericColumnsRow (line 44) | type CoalesceNumericColumnsRow struct
method CoalesceNumericColumns (line 50) | func (q *Queries) CoalesceNumericColumns(ctx context.Context) ([]Coalesc...
constant coalesceNumericNull (line 70) | coalesceNumericNull = `-- name: CoalesceNumericNull :many
type CoalesceNumericNullRow (line 75) | type CoalesceNumericNullRow struct
method CoalesceNumericNull (line 80) | func (q *Queries) CoalesceNumericNull(ctx context.Context) ([]CoalesceNu...
constant coalesceString (line 100) | coalesceString = `-- name: CoalesceString :many
method CoalesceString (line 105) | func (q *Queries) CoalesceString(ctx context.Context) ([]string, error) {
constant coalesceStringColumns (line 125) | coalesceStringColumns = `-- name: CoalesceStringColumns :many
type CoalesceStringColumnsRow (line 130) | type CoalesceStringColumnsRow struct
method CoalesceStringColumns (line 136) | func (q *Queries) CoalesceStringColumns(ctx context.Context) ([]Coalesce...
constant coalesceStringNull (line 156) | coalesceStringNull = `-- name: CoalesceStringNull :many
type CoalesceStringNullRow (line 161) | type CoalesceStringNullRow struct
method CoalesceStringNull (line 166) | func (q *Queries) CoalesceStringNull(ctx context.Context) ([]CoalesceStr...
FILE: internal/endtoend/testdata/coalesce/postgresql/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce/postgresql/stdlib/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce/postgresql/stdlib/go/query.sql.go
constant coalesceNumeric (line 13) | coalesceNumeric = `-- name: CoalesceNumeric :many
method CoalesceNumeric (line 18) | func (q *Queries) CoalesceNumeric(ctx context.Context) ([]int64, error) {
constant coalesceNumericColumns (line 41) | coalesceNumericColumns = `-- name: CoalesceNumericColumns :many
type CoalesceNumericColumnsRow (line 46) | type CoalesceNumericColumnsRow struct
method CoalesceNumericColumns (line 52) | func (q *Queries) CoalesceNumericColumns(ctx context.Context) ([]Coalesc...
constant coalesceNumericNull (line 75) | coalesceNumericNull = `-- name: CoalesceNumericNull :many
type CoalesceNumericNullRow (line 80) | type CoalesceNumericNullRow struct
method CoalesceNumericNull (line 85) | func (q *Queries) CoalesceNumericNull(ctx context.Context) ([]CoalesceNu...
constant coalesceString (line 108) | coalesceString = `-- name: CoalesceString :many
method CoalesceString (line 113) | func (q *Queries) CoalesceString(ctx context.Context) ([]string, error) {
constant coalesceStringColumns (line 136) | coalesceStringColumns = `-- name: CoalesceStringColumns :many
type CoalesceStringColumnsRow (line 141) | type CoalesceStringColumnsRow struct
method CoalesceStringColumns (line 147) | func (q *Queries) CoalesceStringColumns(ctx context.Context) ([]Coalesce...
constant coalesceStringNull (line 170) | coalesceStringNull = `-- name: CoalesceStringNull :many
type CoalesceStringNullRow (line 175) | type CoalesceStringNullRow struct
method CoalesceStringNull (line 180) | func (q *Queries) CoalesceStringNull(ctx context.Context) ([]CoalesceStr...
FILE: internal/endtoend/testdata/coalesce/postgresql/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce/sqlite/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce/sqlite/go/query.sql.go
constant coalesce (line 13) | coalesce = `-- name: Coalesce :many
method Coalesce (line 18) | func (q *Queries) Coalesce(ctx context.Context) ([]string, error) {
constant coalesceColumns (line 41) | coalesceColumns = `-- name: CoalesceColumns :many
type CoalesceColumnsRow (line 46) | type CoalesceColumnsRow struct
method CoalesceColumns (line 52) | func (q *Queries) CoalesceColumns(ctx context.Context) ([]CoalesceColumn...
FILE: internal/endtoend/testdata/coalesce/sqlite/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text, bat text not null)
FILE: internal/endtoend/testdata/coalesce_as/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_as/mysql/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_as/mysql/go/query.sql.go
constant sumBaz (line 13) | sumBaz = `-- name: SumBaz :many
type SumBazRow (line 19) | type SumBazRow struct
method SumBaz (line 24) | func (q *Queries) SumBaz(ctx context.Context) ([]SumBazRow, error) {
FILE: internal/endtoend/testdata/coalesce_as/mysql/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pganalyze/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pganalyze/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pganalyze/go/query.sql.go
constant sumBaz (line 14) | sumBaz = `-- name: SumBaz :many
type SumBazRow (line 20) | type SumBazRow struct
method SumBaz (line 25) | func (q *Queries) SumBaz(ctx context.Context) ([]SumBazRow, error) {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pganalyze/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v4/go/query.sql.go
constant sumBaz (line 13) | sumBaz = `-- name: SumBaz :many
type SumBazRow (line 19) | type SumBazRow struct
method SumBaz (line 24) | func (q *Queries) SumBaz(ctx context.Context) ([]SumBazRow, error) {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v5/go/query.sql.go
constant sumBaz (line 14) | sumBaz = `-- name: SumBaz :many
type SumBazRow (line 20) | type SumBazRow struct
method SumBaz (line 25) | func (q *Queries) SumBaz(ctx context.Context) ([]SumBazRow, error) {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce_as/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/stdlib/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_as/postgresql/stdlib/go/query.sql.go
constant sumBaz (line 13) | sumBaz = `-- name: SumBaz :many
type SumBazRow (line 19) | type SumBazRow struct
method SumBaz (line 24) | func (q *Queries) SumBaz(ctx context.Context) ([]SumBazRow, error) {
FILE: internal/endtoend/testdata/coalesce_as/postgresql/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce_as/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_as/sqlite/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_as/sqlite/go/query.sql.go
constant sumBaz (line 13) | sumBaz = `-- name: SumBaz :many
type SumBazRow (line 19) | type SumBazRow struct
method SumBaz (line 24) | func (q *Queries) SumBaz(ctx context.Context) ([]SumBazRow, error) {
FILE: internal/endtoend/testdata/coalesce_as/sqlite/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/coalesce_join/postgresql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_join/postgresql/go/models.go
type Bar (line 7) | type Bar struct
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/coalesce_join/postgresql/go/query.sql.go
constant getBar (line 12) | getBar = `-- name: GetBar :many
type GetBarRow (line 18) | type GetBarRow struct
method GetBar (line 23) | func (q *Queries) GetBar(ctx context.Context) ([]GetBarRow, error) {
FILE: internal/endtoend/testdata/coalesce_join/postgresql/schema.sql
type foo (line 1) | CREATE TABLE foo(id bigserial primary key)
type bar (line 2) | CREATE TABLE bar(id bigserial primary key)
FILE: internal/endtoend/testdata/coalesce_params/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/coalesce_params/mysql/go/models.go
type CalendarMaincalendar (line 14) | type CalendarMaincalendar
method Scan (line 21) | func (e *CalendarMaincalendar) Scan(src interface{}) error {
constant CalendarMaincalendarTrue (line 17) | CalendarMaincalendarTrue CalendarMaincalendar = "true"
constant CalendarMaincalendarFalse (line 18) | CalendarMaincalendarFalse CalendarMaincalendar = "false"
type NullCalendarMaincalendar (line 33) | type NullCalendarMaincalendar struct
method Scan (line 39) | func (ns *NullCalendarMaincalendar) Scan(value interface{}) error {
method Value (line 49) | func (ns NullCalendarMaincalendar) Value() (driver.Value, error) {
type Author (line 56) | type Author struct
type Calendar (line 63) | type Calendar struct
type Event (line 77) | type Event struct
FILE: internal/endtoend/testdata/coalesce_params/mysql/go/query.sql.go
constant addAuthor (line 12) | addAuthor = `-- name: AddAuthor :execlastid
type AddAuthorParams (line 24) | type AddAuthorParams struct
method AddAuthor (line 30) | func (q *Queries) AddAuthor(ctx context.Context, arg AddAuthorParams) (i...
constant addEvent (line 38) | addEvent = `-- name: AddEvent :execlastid
type AddEventParams (line 46) | type AddEventParams struct
method AddEvent (line 51) | func (q *Queries) AddEvent(ctx context.Context, arg AddEventParams) (int...
FILE: internal/endtoend/testdata/coalesce_params/mysql/schema.sql
type `Calendar` (line 1) | CREATE TABLE `Calendar` (
type `Event` (line 20) | CREATE TABLE `Event` (
type authors (line 38) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/codegen_json/postgresql/schema.sql
type authors (line 1) | CREATE TABLE authors (
FILE: internal/endtoend/testdata/codegen_struct_field_names/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/codegen_struct_field_names/stdlib/go/models.go
type Bar (line 11) | type Bar struct
FILE: internal/endtoend/testdata/codegen_struct_field_names/stdlib/go/query.sql.go
constant test (line 12) | test = `-- name: test :one
method test (line 16) | func (q *Queries) test(ctx context.Context) (Bar, error) {
FILE: internal/endtoend/testdata/codegen_struct_field_names/stdlib/schema.sql
type bar (line 1) | CREATE TABLE bar (
FILE: internal/endtoend/testdata/column_alias/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/column_alias/stdlib/go/models.go
type User (line 11) | type User struct
FILE: internal/endtoend/testdata/column_alias/stdlib/go/query.sql.go
constant getUsers (line 14) | getUsers = `-- name: GetUsers :many
type GetUsersRow (line 37) | type GetUsersRow struct
method GetUsers (line 49) | func (q *Queries) GetUsers(ctx context.Context, searchTerm string) ([]Ge...
FILE: internal/endtoend/testdata/column_alias/stdlib/schema.sql
type users (line 4) | CREATE TABLE users(
FILE: internal/endtoend/testdata/column_as/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/column_as/mysql/go/query.sql.go
constant withAs (line 12) | withAs = `-- name: WithAs :one
type WithAsRow (line 16) | type WithAsRow struct
method WithAs (line 21) | func (q *Queries) WithAs(ctx context.Context) (WithAsRow, error) {
constant withoutAs (line 28) | withoutAs = `-- name: WithoutAs :one
type WithoutAsRow (line 32) | type WithoutAsRow struct
method WithoutAs (line 37) | func (q *Queries) WithoutAs(ctx context.Context) (WithoutAsRow, error) {
FILE: internal/endtoend/testdata/column_as/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/column_as/postgresql/pgx/v4/go/query.sql.go
constant withAs (line 12) | withAs = `-- name: WithAs :one
type WithAsRow (line 16) | type WithAsRow struct
method WithAs (line 21) | func (q *Queries) WithAs(ctx context.Context) (WithAsRow, error) {
constant withoutAs (line 28) | withoutAs = `-- name: WithoutAs :one
type WithoutAsRow (line 32) | type WithoutAsRow struct
method WithoutAs (line 37) | func (q *Queries) WithoutAs(ctx context.Context) (WithoutAsRow, error) {
FILE: internal/endtoend/testdata/column_as/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/column_as/postgresql/pgx/v5/go/query.sql.go
constant withAs (line 12) | withAs = `-- name: WithAs :one
type WithAsRow (line 16) | type WithAsRow struct
method WithAs (line 21) | func (q *Queries) WithAs(ctx context.Context) (WithAsRow, error) {
constant withoutAs (line 28) | withoutAs = `-- name: WithoutAs :one
type WithoutAsRow (line 32) | type WithoutAsRow struct
method WithoutAs (line 37) | func (q *Queries) WithoutAs(ctx context.Context) (WithoutAsRow, error) {
FILE: internal/endtoend/testdata/column_as/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/column_as/postgresql/stdlib/go/query.sql.go
constant withAs (line 12) | withAs = `-- name: WithAs :one
type WithAsRow (line 16) | type WithAsRow struct
method WithAs (line 21) | func (q *Queries) WithAs(ctx context.Context) (WithAsRow, error) {
constant withoutAs (line 28) | withoutAs = `-- name: WithoutAs :one
type WithoutAsRow (line 32) | type WithoutAsRow struct
method WithoutAs (line 37) | func (q *Queries) WithoutAs(ctx context.Context) (WithoutAsRow, error) {
FILE: internal/endtoend/testdata/column_as/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/column_as/sqlite/go/query.sql.go
constant withAs (line 12) | withAs = `-- name: WithAs :one
type WithAsRow (line 16) | type WithAsRow struct
method WithAs (line 21) | func (q *Queries) WithAs(ctx context.Context) (WithAsRow, error) {
constant withoutAs (line 28) | withoutAs = `-- name: WithoutAs :one
type WithoutAsRow (line 32) | type WithoutAsRow struct
method WithoutAs (line 37) | func (q *Queries) WithoutAs(ctx context.Context) (WithoutAsRow, error) {
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v4/go/query.sql.go
constant execFoo (line 15) | execFoo = `-- name: ExecFoo :exec
method ExecFoo (line 20) | func (q *Queries) ExecFoo(ctx context.Context) error {
constant execResultFoo (line 25) | execResultFoo = `-- name: ExecResultFoo :execresult
method ExecResultFoo (line 30) | func (q *Queries) ExecResultFoo(ctx context.Context) (pgconn.CommandTag,...
constant execRowFoo (line 34) | execRowFoo = `-- name: ExecRowFoo :execrows
method ExecRowFoo (line 39) | func (q *Queries) ExecRowFoo(ctx context.Context) (int64, error) {
constant manyFoo (line 47) | manyFoo = `-- name: ManyFoo :many
method ManyFoo (line 52) | func (q *Queries) ManyFoo(ctx context.Context) ([]sql.NullString, error) {
constant oneFoo (line 72) | oneFoo = `-- name: OneFoo :one
method OneFoo (line 77) | func (q *Queries) OneFoo(ctx context.Context) (sql.NullString, error) {
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v5/go/query.sql.go
constant execFoo (line 15) | execFoo = `-- name: ExecFoo :exec
method ExecFoo (line 20) | func (q *Queries) ExecFoo(ctx context.Context) error {
constant execResultFoo (line 25) | execResultFoo = `-- name: ExecResultFoo :execresult
method ExecResultFoo (line 30) | func (q *Queries) ExecResultFoo(ctx context.Context) (pgconn.CommandTag,...
constant execRowFoo (line 34) | execRowFoo = `-- name: ExecRowFoo :execrows
method ExecRowFoo (line 39) | func (q *Queries) ExecRowFoo(ctx context.Context) (int64, error) {
constant manyFoo (line 47) | manyFoo = `-- name: ManyFoo :many
method ManyFoo (line 52) | func (q *Queries) ManyFoo(ctx context.Context) ([]pgtype.Text, error) {
constant oneFoo (line 72) | oneFoo = `-- name: OneFoo :one
method OneFoo (line 77) | func (q *Queries) OneFoo(ctx context.Context) (pgtype.Text, error) {
FILE: internal/endtoend/testdata/comment_godoc/postgresql/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New() *Queries {
type Queries (line 24) | type Queries struct
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v4/go/query.sql.go
constant execFoo (line 15) | execFoo = `-- name: ExecFoo :exec
method ExecFoo (line 20) | func (q *Queries) ExecFoo(ctx context.Context, db DBTX) error {
constant execResultFoo (line 25) | execResultFoo = `-- name: ExecResultFoo :execresult
method ExecResultFoo (line 30) | func (q *Queries) ExecResultFoo(ctx context.Context, db DBTX) (pgconn.Co...
constant execRowFoo (line 34) | execRowFoo = `-- name: ExecRowFoo :execrows
method ExecRowFoo (line 39) | func (q *Queries) ExecRowFoo(ctx context.Context, db DBTX) (int64, error) {
constant manyFoo (line 47) | manyFoo = `-- name: ManyFoo :many
method ManyFoo (line 52) | func (q *Queries) ManyFoo(ctx context.Context, db DBTX) ([]sql.NullStrin...
constant oneFoo (line 72) | oneFoo = `-- name: OneFoo :one
method OneFoo (line 77) | func (q *Queries) OneFoo(ctx context.Context, db DBTX) (sql.NullString, ...
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New() *Queries {
type Queries (line 24) | type Queries struct
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v5/go/query.sql.go
constant execFoo (line 15) | execFoo = `-- name: ExecFoo :exec
method ExecFoo (line 20) | func (q *Queries) ExecFoo(ctx context.Context, db DBTX) error {
constant execResultFoo (line 25) | execResultFoo = `-- name: ExecResultFoo :execresult
method ExecResultFoo (line 30) | func (q *Queries) ExecResultFoo(ctx context.Context, db DBTX) (pgconn.Co...
constant execRowFoo (line 34) | execRowFoo = `-- name: ExecRowFoo :execrows
method ExecRowFoo (line 39) | func (q *Queries) ExecRowFoo(ctx context.Context, db DBTX) (int64, error) {
constant manyFoo (line 47) | manyFoo = `-- name: ManyFoo :many
method ManyFoo (line 52) | func (q *Queries) ManyFoo(ctx context.Context, db DBTX) ([]pgtype.Text, ...
constant oneFoo (line 72) | oneFoo = `-- name: OneFoo :one
method OneFoo (line 77) | func (q *Queries) OneFoo(ctx context.Context, db DBTX) (pgtype.Text, err...
FILE: internal/endtoend/testdata/comment_godoc_db_argument/postgresql/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v4/go/models.go
type FooMood (line 13) | type FooMood
method Scan (line 21) | func (e *FooMood) Scan(src interface{}) error {
constant FooMoodSad (line 16) | FooMoodSad FooMood = "sad"
constant FooMoodOk (line 17) | FooMoodOk FooMood = "ok"
constant FooMoodHappy (line 18) | FooMoodHappy FooMood = "happy"
type NullFooMood (line 33) | type NullFooMood struct
method Scan (line 39) | func (ns *NullFooMood) Scan(value interface{}) error {
method Value (line 49) | func (ns NullFooMood) Value() (driver.Value, error) {
type FooBar (line 57) | type FooBar struct
type FooBat (line 63) | type FooBat struct
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v4/go/query.sql.go
constant listBar (line 12) | listBar = `-- name: ListBar :many
method ListBar (line 16) | func (q *Queries) ListBar(ctx context.Context) ([]string, error) {
constant listBat (line 36) | listBat = `-- name: ListBat :many
method ListBat (line 40) | func (q *Queries) ListBat(ctx context.Context) ([]string, error) {
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v4/schema.sql
type foo (line 3) | CREATE TABLE foo.bar (
type foo (line 7) | CREATE VIEW foo.bat AS SELECT * FROM foo.bar
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v5/go/models.go
type FooMood (line 13) | type FooMood
method Scan (line 21) | func (e *FooMood) Scan(src interface{}) error {
constant FooMoodSad (line 16) | FooMoodSad FooMood = "sad"
constant FooMoodOk (line 17) | FooMoodOk FooMood = "ok"
constant FooMoodHappy (line 18) | FooMoodHappy FooMood = "happy"
type NullFooMood (line 33) | type NullFooMood struct
method Scan (line 39) | func (ns *NullFooMood) Scan(value interface{}) error {
method Value (line 49) | func (ns NullFooMood) Value() (driver.Value, error) {
type FooBar (line 57) | type FooBar struct
type FooBat (line 63) | type FooBat struct
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v5/go/query.sql.go
constant listBar (line 12) | listBar = `-- name: ListBar :many
method ListBar (line 16) | func (q *Queries) ListBar(ctx context.Context) ([]string, error) {
constant listBat (line 36) | listBat = `-- name: ListBat :many
method ListBat (line 40) | func (q *Queries) ListBat(ctx context.Context) ([]string, error) {
FILE: internal/endtoend/testdata/comment_on/postgresql/pgx/v5/schema.sql
type foo (line 3) | CREATE TABLE foo.bar (
type foo (line 7) | CREATE VIEW foo.bat AS SELECT * FROM foo.bar
FILE: internal/endtoend/testdata/comment_on/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_on/postgresql/stdlib/go/models.go
type FooMood (line 13) | type FooMood
method Scan (line 21) | func (e *FooMood) Scan(src interface{}) error {
constant FooMoodSad (line 16) | FooMoodSad FooMood = "sad"
constant FooMoodOk (line 17) | FooMoodOk FooMood = "ok"
constant FooMoodHappy (line 18) | FooMoodHappy FooMood = "happy"
type NullFooMood (line 33) | type NullFooMood struct
method Scan (line 39) | func (ns *NullFooMood) Scan(value interface{}) error {
method Value (line 49) | func (ns NullFooMood) Value() (driver.Value, error) {
type FooBar (line 57) | type FooBar struct
type FooBat (line 63) | type FooBat struct
FILE: internal/endtoend/testdata/comment_on/postgresql/stdlib/go/query.sql.go
constant listBar (line 12) | listBar = `-- name: ListBar :many
method ListBar (line 16) | func (q *Queries) ListBar(ctx context.Context) ([]string, error) {
constant listBat (line 39) | listBat = `-- name: ListBat :many
method ListBat (line 43) | func (q *Queries) ListBat(ctx context.Context) ([]string, error) {
FILE: internal/endtoend/testdata/comment_on/postgresql/stdlib/schema.sql
type foo (line 3) | CREATE TABLE foo.bar (
type foo (line 7) | CREATE VIEW foo.bat AS SELECT * FROM foo.bar
FILE: internal/endtoend/testdata/comment_syntax/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_syntax/mysql/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_syntax/mysql/go/query.sql.go
constant doubleDash (line 13) | doubleDash = `-- name: DoubleDash :one
method DoubleDash (line 17) | func (q *Queries) DoubleDash(ctx context.Context) (sql.NullString, error) {
constant hash (line 24) | hash = `-- name: Hash :one
method Hash (line 28) | func (q *Queries) Hash(ctx context.Context) (sql.NullString, error) {
constant slashStar (line 35) | slashStar = `-- name: SlashStar :one
method SlashStar (line 39) | func (q *Queries) SlashStar(ctx context.Context) (sql.NullString, error) {
FILE: internal/endtoend/testdata/comment_syntax/mysql/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v4/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v4/go/query.sql.go
constant doubleDash (line 13) | doubleDash = `-- name: DoubleDash :one
method DoubleDash (line 17) | func (q *Queries) DoubleDash(ctx context.Context) (sql.NullString, error) {
constant slashStar (line 24) | slashStar = `-- name: SlashStar :one
method SlashStar (line 28) | func (q *Queries) SlashStar(ctx context.Context) (sql.NullString, error) {
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v4/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v5/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v5/go/query.sql.go
constant doubleDash (line 14) | doubleDash = `-- name: DoubleDash :one
method DoubleDash (line 18) | func (q *Queries) DoubleDash(ctx context.Context) (pgtype.Text, error) {
constant slashStar (line 25) | slashStar = `-- name: SlashStar :one
method SlashStar (line 29) | func (q *Queries) SlashStar(ctx context.Context) (pgtype.Text, error) {
FILE: internal/endtoend/testdata/comment_syntax/postgresql/pgx/v5/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/comment_syntax/postgresql/stdlib/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_syntax/postgresql/stdlib/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_syntax/postgresql/stdlib/go/query.sql.go
constant doubleDash (line 13) | doubleDash = `-- name: DoubleDash :one
method DoubleDash (line 17) | func (q *Queries) DoubleDash(ctx context.Context) (sql.NullString, error) {
constant slashStar (line 24) | slashStar = `-- name: SlashStar :one
method SlashStar (line 28) | func (q *Queries) SlashStar(ctx context.Context) (sql.NullString, error) {
FILE: internal/endtoend/testdata/comment_syntax/postgresql/stdlib/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/comment_syntax/sqlite/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/comment_syntax/sqlite/go/models.go
type Foo (line 11) | type Foo struct
FILE: internal/endtoend/testdata/comment_syntax/sqlite/go/query.sql.go
constant doubleDash (line 13) | doubleDash = `-- name: DoubleDash :one
method DoubleDash (line 17) | func (q *Queries) DoubleDash(ctx context.Context) (sql.NullString, error) {
constant slashStar (line 24) | slashStar = `-- name: SlashStar :one
method SlashStar (line 28) | func (q *Queries) SlashStar(ctx context.Context) (sql.NullString, error) {
FILE: internal/endtoend/testdata/comment_syntax/sqlite/schema.sql
type foo (line 1) | CREATE TABLE foo (bar text)
FILE: internal/endtoend/testdata/comparisons/mysql/go/db.go
type DBTX (line 12) | type DBTX interface
function New (line 19) | func New(db DBTX) *Queries {
type Queries (line 23) | type Queries struct
method WithTx (line 27) | func (q *Queries) WithTx(tx *sql.Tx) *Queries {
FILE: internal/endtoend/testdata/comparisons/mysql/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/comparisons/mysql/go/query.sql.go
constant alsoNotEqual (line 12) | alsoNotEqual = `-- name: AlsoNotEqual :many
method AlsoNotEqual (line 16) | func (q *Queries) AlsoNotEqual(ctx context.Context) ([]bool, error) {
constant equal (line 39) | equal = `-- name: Equal :many
method Equal (line 43) | func (q *Queries) Equal(ctx context.Context) ([]bool, error) {
constant greaterThan (line 66) | greaterThan = `-- name: GreaterThan :many
method GreaterThan (line 70) | func (q *Queries) GreaterThan(ctx context.Context) ([]bool, error) {
constant greaterThanOrEqual (line 93) | greaterThanOrEqual = `-- name: GreaterThanOrEqual :many
method GreaterThanOrEqual (line 97) | func (q *Queries) GreaterThanOrEqual(ctx context.Context) ([]bool, error) {
constant isNotNull (line 120) | isNotNull = `-- name: IsNotNull :many
method IsNotNull (line 124) | func (q *Queries) IsNotNull(ctx context.Context) ([]bool, error) {
constant isNull (line 147) | isNull = `-- name: IsNull :many
method IsNull (line 151) | func (q *Queries) IsNull(ctx context.Context) ([]bool, error) {
constant lessThan (line 174) | lessThan = `-- name: LessThan :many
method LessThan (line 178) | func (q *Queries) LessThan(ctx context.Context) ([]bool, error) {
constant lessThanOrEqual (line 201) | lessThanOrEqual = `-- name: LessThanOrEqual :many
method LessThanOrEqual (line 205) | func (q *Queries) LessThanOrEqual(ctx context.Context) ([]bool, error) {
constant notEqual (line 228) | notEqual = `-- name: NotEqual :many
method NotEqual (line 232) | func (q *Queries) NotEqual(ctx context.Context) ([]bool, error) {
FILE: internal/endtoend/testdata/comparisons/mysql/schema.sql
type bar (line 4) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v4/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v4/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v4/go/query.sql.go
constant alsoNotEqual (line 12) | alsoNotEqual = `-- name: AlsoNotEqual :many
method AlsoNotEqual (line 16) | func (q *Queries) AlsoNotEqual(ctx context.Context) ([]bool, error) {
constant equal (line 36) | equal = `-- name: Equal :many
method Equal (line 40) | func (q *Queries) Equal(ctx context.Context) ([]bool, error) {
constant greaterThan (line 60) | greaterThan = `-- name: GreaterThan :many
method GreaterThan (line 64) | func (q *Queries) GreaterThan(ctx context.Context) ([]bool, error) {
constant greaterThanOrEqual (line 84) | greaterThanOrEqual = `-- name: GreaterThanOrEqual :many
method GreaterThanOrEqual (line 88) | func (q *Queries) GreaterThanOrEqual(ctx context.Context) ([]bool, error) {
constant lessThan (line 108) | lessThan = `-- name: LessThan :many
method LessThan (line 112) | func (q *Queries) LessThan(ctx context.Context) ([]bool, error) {
constant lessThanOrEqual (line 132) | lessThanOrEqual = `-- name: LessThanOrEqual :many
method LessThanOrEqual (line 136) | func (q *Queries) LessThanOrEqual(ctx context.Context) ([]bool, error) {
constant notEqual (line 156) | notEqual = `-- name: NotEqual :many
method NotEqual (line 160) | func (q *Queries) NotEqual(ctx context.Context) ([]bool, error) {
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v4/schema.sql
type bar (line 4) | CREATE TABLE bar (id serial not null)
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v5/go/db.go
type DBTX (line 14) | type DBTX interface
function New (line 20) | func New(db DBTX) *Queries {
type Queries (line 24) | type Queries struct
method WithTx (line 28) | func (q *Queries) WithTx(tx pgx.Tx) *Queries {
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v5/go/models.go
type Bar (line 7) | type Bar struct
FILE: internal/endtoend/testdata/comparisons/postgresql/pgx/v5/go/query.sql.go
constant alsoNotEqual (line 12) | alsoNotEqual = `-- name: AlsoNotEqual :many
method AlsoNotEqual (line 16) | func (q *Queries) AlsoNotEqual(ctx context.Context) ([]bool, error) {
constant equal (line 36) | equal = `-- name: Equal :many
method Equal (line 40) | func (q *Queries) Equal(ctx context.Context) ([]bool, error) {
constant greaterThan (line 60) | greaterThan = `-- name: GreaterThan :many
method GreaterThan (line 64) | func (q *Queries) GreaterThan(ctx context.Context) ([]bool, error) {
constant greaterThanOrEqual (line 84) | greaterThanOrEqual = `-- name: GreaterThanOrEqual :many
method GreaterThanOrEqual (line 88) | func (q *Queries) GreaterThanOrEqual(ctx context.Context) ([]bool, error) {
constant lessThan (line 108) | lessThan = `-- name: LessThan :many
method LessThan (line 112) | func (q *Queries) LessThan(ctx context.Context) ([]bool, error) {
Copy disabled (too large)
Download .json
Condensed preview — 6671 files, each showing path, character count, and a content snippet. Download the .json file for the full structured content (14,976K chars).
[
{
"path": ".github/ISSUE_TEMPLATE/BUG_REPORT.yml",
"chars": 2430,
"preview": "name: Bug Report\ndescription: File a bug report\nlabels: [bug]\nbody:\n - type: dropdown\n id: version\n attributes:\n "
},
{
"path": ".github/ISSUE_TEMPLATE/FEATURE_REQUEST.yml",
"chars": 721,
"preview": "name: Feature Request\ndescription: Request a new feature or a change to an existing feature\nlabels: [enhancement]\nbody:\n"
},
{
"path": ".github/dependabot.yml",
"chars": 864,
"preview": "version: 2\nupdates:\n - package-ecosystem: \"gomod\"\n directory: \"/\"\n schedule:\n interval: \"daily\"\n groups:\n"
},
{
"path": ".github/workflows/buf.yml",
"chars": 199,
"preview": "name: buf\non: pull_request\njobs:\n build:\n runs-on: ubuntu-latest\n steps:\n - uses: actions/checkout@v6\n "
},
{
"path": ".github/workflows/build.yml",
"chars": 398,
"preview": "name: build\non:\n workflow_dispatch:\njobs:\n build:\n strategy:\n matrix:\n os: [ubuntu-24.04, macos-14, win"
},
{
"path": ".github/workflows/ci-kotlin.yml",
"chars": 563,
"preview": "name: kotlin\non:\n push:\n branches:\n - main\n pull_request:\njobs:\n build:\n if: false\n name: test\n runs"
},
{
"path": ".github/workflows/ci-python.yml",
"chars": 562,
"preview": "name: python\non:\n push:\n branches:\n - main\n pull_request:\njobs:\n build:\n if: false\n name: test\n runs"
},
{
"path": ".github/workflows/ci-typescript.yml",
"chars": 596,
"preview": "name: typescript\non:\n push:\n branches:\n - main\n pull_request:\njobs:\n build:\n if: false\n name: test\n "
},
{
"path": ".github/workflows/ci.yml",
"chars": 2003,
"preview": "name: go\non:\n push:\n branches:\n - main\n pull_request:\njobs:\n build:\n strategy:\n matrix:\n goos:"
},
{
"path": ".github/workflows/gen.yml",
"chars": 1087,
"preview": "name: sqlc-pg-gen\non:\n workflow_dispatch:\njobs:\n gen:\n name: sqlc-pg-gen\n runs-on: ubuntu-22.04\n services:\n "
},
{
"path": ".gitignore",
"chars": 89,
"preview": "/.idea/\n__pycache__\n.DS_Store\n.*.swp\n\n# Devenv\n.envrc\n.direnv\n.devenv*\ndevenv.local.nix\n\n"
},
{
"path": ".readthedocs.yaml",
"chars": 571,
"preview": "# .readthedocs.yaml\n# Read the Docs configuration file\n# See https://docs.readthedocs.io/en/stable/config-file/v2.html f"
},
{
"path": ".vscode/settings.json",
"chars": 41,
"preview": "{\n \"files.insertFinalNewline\": true\n}\n"
},
{
"path": "CLAUDE.md",
"chars": 7291,
"preview": "# Claude Code Development Guide for sqlc\n\nThis document provides essential information for working with the sqlc codebas"
},
{
"path": "Dockerfile",
"chars": 396,
"preview": "# STEP 1: Build sqlc\nFROM golang:1.26.0 AS builder\n\nCOPY . /workspace\nWORKDIR /workspace\n\nARG github_ref\nARG github_sha\n"
},
{
"path": "LICENSE",
"chars": 1067,
"preview": "MIT License\n\nCopyright (c) 2024 Riza, Inc.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy"
},
{
"path": "Makefile",
"chars": 1414,
"preview": ".PHONY: build build-endtoend test test-ci test-examples test-endtoend start psql mysqlsh proto\n\nbuild:\n\tgo build ./...\n\n"
},
{
"path": "README.md",
"chars": 3016,
"preview": "# sqlc: A SQL Compiler\n\n\n[\n\n[changelog]\n# changelog header\nheader = \"\"\"\n# Changelog\nAll notable changes "
},
{
"path": "cmd/sqlc/main.go",
"chars": 152,
"preview": "package main\n\nimport (\n\t\"os\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/cmd\"\n)\n\nfunc main() {\n\tos.Exit(cmd.Do(os.Args[1:], os."
},
{
"path": "cmd/sqlc-gen-json/main.go",
"chars": 833,
"preview": "package main\n\nimport (\n\t\"bufio\"\n\t\"context\"\n\t\"fmt\"\n\t\"io\"\n\t\"os\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/json\"\n\t\"githu"
},
{
"path": "cmd/sqlc-test-setup/main.go",
"chars": 22674,
"preview": "package main\n\nimport (\n\t\"crypto/sha256\"\n\t\"encoding/hex\"\n\t\"fmt\"\n\t\"io\"\n\t\"log\"\n\t\"net/http\"\n\t\"os\"\n\t\"os/exec\"\n\t\"path/filepath"
},
{
"path": "devenv.nix",
"chars": 250,
"preview": "{ pkgs, ... }:\n\n{\n # https://devenv.sh/packages/\n packages = [ \n pkgs.buf\n pkgs.go_1_24\n pkgs.git\n pkgs.gi"
},
{
"path": "devenv.yaml",
"chars": 66,
"preview": "inputs:\n nixpkgs:\n url: github:NixOS/nixpkgs/nixpkgs-unstable\n"
},
{
"path": "docker-compose.yml",
"chars": 433,
"preview": "version: \"3.8\"\nservices:\n mysql:\n image: \"mysql:9\"\n ports:\n - \"3306:3306\"\n restart: always\n environmen"
},
{
"path": "docs/.gitignore",
"chars": 13,
"preview": "_venv\n_build\n"
},
{
"path": "docs/Makefile",
"chars": 828,
"preview": "# Minimal makefile for Sphinx documentation\n#\n\n# You can set these variables from the command line, and also\n# from the "
},
{
"path": "docs/_static/customize.css",
"chars": 346,
"preview": ".wy-side-nav-search img {\n padding: 5px 60px !important;\n}\n\n#banner {\n text-align: center;\n background: #2980b9;\n bo"
},
{
"path": "docs/_templates/breadcrumbs.html",
"chars": 121,
"preview": "{% extends \"!breadcrumbs.html\" %}\n\n{% block breadcrumbs %}\n{% if show_banner %}\n{% endif %}\n{{ super() }}\n{% endblock %}"
},
{
"path": "docs/_templates/layout.html",
"chars": 506,
"preview": "{% extends \"!layout.html\" %}\n\n{% block extrahead %}\n<script defer data-domain=\"docs.sqlc.dev\" data-api=\"https://proxy.sq"
},
{
"path": "docs/conf.py",
"chars": 2428,
"preview": "# Configuration file for the Sphinx documentation builder.\n#\n# This file only contains a selection of the most common op"
},
{
"path": "docs/guides/development.md",
"chars": 1065,
"preview": "# Developing sqlc\n\n## Building\n\nFor local development, install `sqlc` under an alias. We suggest `sqlc-dev`.\n\n```\ngo bui"
},
{
"path": "docs/guides/migrating-off-hosted-managed-databases.md",
"chars": 1755,
"preview": "# Migrating off hosted managed databases\n \nStarting in sqlc 1.27.0, [managed databases](../docs/managed-databases.md) wi"
},
{
"path": "docs/guides/migrating-to-sqlc-gen-kotlin.md",
"chars": 2780,
"preview": "# Migrating to sqlc-gen-kotlin\n \nStarting in sqlc 1.16.0, built-in Kotlin support has been deprecated. It will\nbe fully "
},
{
"path": "docs/guides/migrating-to-sqlc-gen-python.md",
"chars": 3060,
"preview": "# Migrating to sqlc-gen-python\n \nStarting in sqlc 1.16.0, built-in Python support has been deprecated. It will\nbe fully "
},
{
"path": "docs/guides/plugins.md",
"chars": 3403,
"preview": "# Using plugins\n\nTo use plugins, you must be using [Version 2](../reference/config.md#version-2) of\nthe configuration fi"
},
{
"path": "docs/guides/privacy.md",
"chars": 1718,
"preview": "# Privacy and data collection\n\nThese days, it feels like every piece of software is tracking you. From your\nbrowser, to "
},
{
"path": "docs/guides/using-go-and-pgx.rst",
"chars": 3135,
"preview": "================\nUsing Go and pgx\n================\n\n.. note::\n :code:`pgx/v5` is supported starting from v1.18.0.\n\n\npg"
},
{
"path": "docs/howto/ci-cd.md",
"chars": 4533,
"preview": "# Using sqlc in CI/CD\n\nIf your project has more than a single developer, we suggest running `sqlc` as\npart of your CI/CD"
},
{
"path": "docs/howto/ddl.md",
"chars": 4022,
"preview": "# Modifying the database schema\n\nsqlc parses `CREATE TABLE` and `ALTER TABLE` statements in order to generate\nthe necess"
},
{
"path": "docs/howto/delete.md",
"chars": 824,
"preview": "# Deleting rows\n\n```sql\nCREATE TABLE authors (\n id SERIAL PRIMARY KEY,\n bio text NOT NULL\n);\n```\n\nThe"
},
{
"path": "docs/howto/embedding.md",
"chars": 1300,
"preview": "#### Embedding structs\n\nEmbedding allows you to reuse existing model structs in more queries, resulting\nin less manual s"
},
{
"path": "docs/howto/generate.md",
"chars": 2773,
"preview": "# `generate` - Generating code\n\n`sqlc generate` parses SQL, analyzes the results, and outputs code. Your schema and quer"
},
{
"path": "docs/howto/insert.md",
"chars": 4588,
"preview": "# Inserting rows\n\n```sql\nCREATE TABLE authors (\n id SERIAL PRIMARY KEY,\n bio text NOT NULL\n);\n```\n\nTh"
},
{
"path": "docs/howto/managed-databases.md",
"chars": 3094,
"preview": "# Managed databases\n\n*Added in v1.22.0*\n\n`sqlc` can automatically create read-only databases to power query analysis,\nli"
},
{
"path": "docs/howto/named_parameters.md",
"chars": 2003,
"preview": "# Naming parameters\n\nsqlc tries to generate good names for positional parameters, but sometimes it\nlacks enough context."
},
{
"path": "docs/howto/overrides.md",
"chars": 6375,
"preview": "# Overriding types\n\n:::{note}\nType overrides and field renaming are only fully-supported for Go.\n:::\n\nIn many cases it's"
},
{
"path": "docs/howto/prepared_query.md",
"chars": 2040,
"preview": "# Preparing queries\n\nIf you're using `pgx/v5` you get its\n[implicit support](https://github.com/jackc/pgx/wiki/Automatic"
},
{
"path": "docs/howto/push.md",
"chars": 2056,
"preview": "# `push` - Uploading projects\n\n```{note}\n`push` is powered by [sqlc Cloud](https://dashboard.sqlc.dev). Sign up for [fre"
},
{
"path": "docs/howto/query_count.md",
"chars": 1570,
"preview": "# Counting rows\n\n```sql\nCREATE TABLE authors (\n id SERIAL PRIMARY KEY,\n hometown text NOT NULL\n);\n\n-- name: Co"
},
{
"path": "docs/howto/rename.md",
"chars": 2282,
"preview": "# Renaming fields\n\nStruct field names are generated from column names using a simple algorithm:\nsplit the column name on"
},
{
"path": "docs/howto/select.md",
"chars": 8979,
"preview": "# Retrieving rows\n\nTo generate a database access method, annotate a query with a specific comment.\n\n```sql\nCREATE TABLE "
},
{
"path": "docs/howto/structs.md",
"chars": 1003,
"preview": "# Configuring generated structs\n\n## Naming scheme\n\nStructs generated from tables will attempt to use the singular form o"
},
{
"path": "docs/howto/transactions.md",
"chars": 2023,
"preview": "# Using transactions\nIn the code generated by sqlc, the `WithTx` method allows a `Queries` instance to be associated wit"
},
{
"path": "docs/howto/update.md",
"chars": 1970,
"preview": "# Updating rows\n\n```sql\nCREATE TABLE authors (\n id SERIAL PRIMARY KEY,\n bio text NOT NULL\n);\n```\n\n## "
},
{
"path": "docs/howto/verify.md",
"chars": 4027,
"preview": "# `verify` - Verifying schema changes\n\n*Added in v1.24.0*\n\nSchema updates and poorly-written queries often bring down pr"
},
{
"path": "docs/howto/vet.md",
"chars": 8505,
"preview": "# `vet` - Linting queries\n\n*Added in v1.19.0*\n\n`sqlc vet` runs queries through a set of lint rules.\n\nRules are defined i"
},
{
"path": "docs/index.rst",
"chars": 2066,
"preview": ".. sqlc documentation master file, created by\n sphinx-quickstart on Mon Feb 1 23:18:36 2021.\n You can adapt this fi"
},
{
"path": "docs/overview/install.md",
"chars": 909,
"preview": "# Installing sqlc\n\nsqlc is distributed as a single binary with zero dependencies.\n\n## macOS\n\n```\nbrew install sqlc\n```\n\n"
},
{
"path": "docs/reference/changelog.md",
"chars": 90410,
"preview": "# Changelog\nAll notable changes to this project will be documented in this file.\n\n(v1-30-0)=\n## [1.30.0](https://github."
},
{
"path": "docs/reference/cli.md",
"chars": 989,
"preview": "# CLI\n\n```sh\nUsage:\n sqlc [command]\n\nAvailable Commands:\n compile Statically check SQL for syntax and type errors\n"
},
{
"path": "docs/reference/config.md",
"chars": 18087,
"preview": "# Configuration\n\nThe `sqlc` tool is configured via a `sqlc.(yaml|yml)` or `sqlc.json` file. This\nfile must be in the dir"
},
{
"path": "docs/reference/datatypes.md",
"chars": 6913,
"preview": "# Datatypes\n\n`sqlc` attempts to make reasonable default choices when mapping internal\ndatabase types to Go types. Choice"
},
{
"path": "docs/reference/environment-variables.md",
"chars": 6006,
"preview": "# Environment variables\n\n## SQLCEXPERIMENT\n\nThe `SQLCEXPERIMENT` variable controls experimental features within sqlc. It"
},
{
"path": "docs/reference/language-support.rst",
"chars": 3583,
"preview": "Database and language support\n#############################\n\n========== ======================= ============ ========"
},
{
"path": "docs/reference/macros.md",
"chars": 2660,
"preview": "# Macros\n\n## `sqlc.arg`\n\nAttach a name to a parameter in a SQL query. This macro expands to an\nengine-specific parameter"
},
{
"path": "docs/reference/query-annotations.md",
"chars": 5383,
"preview": "# Query annotations\n\nsqlc requires each query to have a small comment indicating the name and\ncommand. The format of thi"
},
{
"path": "docs/requirements.txt",
"chars": 550,
"preview": "Babel==2.17.0\nJinja2==3.1.6\nMarkupSafe==3.0.3\nPygments==2.19.2\nSphinx==7.4.7\ncertifi==2026.1.4\nchardet==5.2.0\ncommonmark"
},
{
"path": "docs/tutorials/getting-started-mysql.md",
"chars": 5175,
"preview": "# Getting started with MySQL\n\nThis tutorial assumes that the latest version of sqlc is\n[installed](../overview/install.m"
},
{
"path": "docs/tutorials/getting-started-postgresql.md",
"chars": 5831,
"preview": "# Getting started with PostgreSQL\n\nThis tutorial assumes that the latest version of sqlc is\n[installed](../overview/inst"
},
{
"path": "docs/tutorials/getting-started-sqlite.md",
"chars": 4153,
"preview": "# Getting started with SQLite\n\nThis tutorial assumes that the latest version of sqlc is\n[installed](../overview/install."
},
{
"path": "examples/authors/mysql/db.go",
"chars": 600,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage authors\n\nimport (\n\t\"context\"\n\t\"database/"
},
{
"path": "examples/authors/mysql/db_test.go",
"chars": 1007,
"preview": "//go:build examples\n\npackage authors\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"testing\"\n\n\t_ \"github.com/go-sql-driver/mysql"
},
{
"path": "examples/authors/mysql/models.go",
"chars": 186,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage authors\n\nimport (\n\t\"database/sql\"\n)\n\ntyp"
},
{
"path": "examples/authors/mysql/query.sql",
"chars": 299,
"preview": "/* name: GetAuthor :one */\nSELECT * FROM authors\nWHERE id = ? LIMIT 1;\n\n/* name: ListAuthors :many */\nSELECT * FROM auth"
},
{
"path": "examples/authors/mysql/query.sql.go",
"chars": 1601,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage authors\n\nimport (\n\t"
},
{
"path": "examples/authors/mysql/schema.sql",
"chars": 131,
"preview": "CREATE TABLE authors (\n id BIGINT PRIMARY KEY AUTO_INCREMENT,\n name text NOT NULL,\n bi"
},
{
"path": "examples/authors/postgresql/db.go",
"chars": 569,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage authors\n\nimport (\n\t\"context\"\n\n\t\"github.c"
},
{
"path": "examples/authors/postgresql/db_test.go",
"chars": 961,
"preview": "//go:build examples\n\npackage authors\n\nimport (\n\t\"context\"\n\t\"testing\"\n\n\t\"github.com/jackc/pgx/v5\"\n\t\"github.com/jackc/pgx/"
},
{
"path": "examples/authors/postgresql/models.go",
"chars": 201,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage authors\n\nimport (\n\t\"github.com/jackc/pgx"
},
{
"path": "examples/authors/postgresql/query.sql",
"chars": 303,
"preview": "-- name: GetAuthor :one\nSELECT * FROM authors\nWHERE id = $1 LIMIT 1;\n\n-- name: ListAuthors :many\nSELECT * FROM authors\nO"
},
{
"path": "examples/authors/postgresql/query.sql.go",
"chars": 1628,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage authors\n\nimport (\n\t"
},
{
"path": "examples/authors/postgresql/schema.sql",
"chars": 119,
"preview": "CREATE TABLE authors (\n id BIGSERIAL PRIMARY KEY,\n name text NOT NULL,\n bio text\n);\n"
},
{
"path": "examples/authors/sqlc.yaml",
"chars": 1186,
"preview": "version: '2'\ncloud:\n project: \"01HAQMMECEYQYKFJN8MP16QC41\"\nsql:\n- name: postgresql\n schema: postgresql/schema.sql\n qu"
},
{
"path": "examples/authors/sqlite/db.go",
"chars": 600,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage authors\n\nimport (\n\t\"context\"\n\t\"database/"
},
{
"path": "examples/authors/sqlite/db_test.go",
"chars": 922,
"preview": "//go:build examples\n\npackage authors\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"testing\"\n\n\t\"github.com/sqlc-dev/sqlc/interna"
},
{
"path": "examples/authors/sqlite/models.go",
"chars": 186,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage authors\n\nimport (\n\t\"database/sql\"\n)\n\ntyp"
},
{
"path": "examples/authors/sqlite/query.sql",
"chars": 299,
"preview": "/* name: GetAuthor :one */\nSELECT * FROM authors\nWHERE id = ? LIMIT 1;\n\n/* name: ListAuthors :many */\nSELECT * FROM auth"
},
{
"path": "examples/authors/sqlite/query.sql.go",
"chars": 1601,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage authors\n\nimport (\n\t"
},
{
"path": "examples/authors/sqlite/schema.sql",
"chars": 131,
"preview": "CREATE TABLE authors (\n id integer PRIMARY KEY AUTOINCREMENT,\n name text NOT NULL,\n bi"
},
{
"path": "examples/batch/postgresql/batch.go",
"chars": 7925,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: batch.go\n\npackage batch\n\nimport (\n\t\"co"
},
{
"path": "examples/batch/postgresql/db.go",
"chars": 624,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage batch\n\nimport (\n\t\"context\"\n\n\t\"github.com"
},
{
"path": "examples/batch/postgresql/db_test.go",
"chars": 3795,
"preview": "//go:build examples\n\npackage batch\n\nimport (\n\t\"context\"\n\t\"testing\"\n\t\"time\"\n\n\t\"github.com/jackc/pgx/v5\"\n\t\"github.com/jack"
},
{
"path": "examples/batch/postgresql/models.go",
"chars": 1581,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage batch\n\nimport (\n\t\"database/sql/driver\"\n\t"
},
{
"path": "examples/batch/postgresql/querier.go",
"chars": 986,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage batch\n\nimport (\n\t\"context\"\n\n\t\"github.com"
},
{
"path": "examples/batch/postgresql/query.sql",
"chars": 942,
"preview": "-- name: GetAuthor :one\nSELECT * FROM authors\nWHERE author_id = $1;\n\n-- name: DeleteBookExecResult :execresult\nDELETE FR"
},
{
"path": "examples/batch/postgresql/query.sql.go",
"chars": 1109,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage batch\n\nimport (\n\t\"c"
},
{
"path": "examples/batch/postgresql/schema.sql",
"chars": 656,
"preview": "CREATE TABLE authors (\n author_id SERIAL PRIMARY KEY,\n name text NOT NULL DEFAULT '',\n biogra"
},
{
"path": "examples/batch/sqlc.json",
"chars": 595,
"preview": "{\n \"version\": \"1\",\n \"cloud\": {\n \"project\": \"01HAQMMECEYQYKFJN8MP16QC41\"\n },\n \"packages\": [\n {\n \"path\": \"p"
},
{
"path": "examples/booktest/mysql/db.go",
"chars": 601,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage booktest\n\nimport (\n\t\"context\"\n\t\"database"
},
{
"path": "examples/booktest/mysql/db_test.go",
"chars": 3521,
"preview": "//go:build examples\n\npackage booktest\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"testing\"\n\t\"time\"\n\n\t_ \"github.com/go-sql-dri"
},
{
"path": "examples/booktest/mysql/models.go",
"chars": 1321,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage booktest\n\nimport (\n\t\"database/sql/driver"
},
{
"path": "examples/booktest/mysql/query.sql",
"chars": 1067,
"preview": "/* name: GetAuthor :one */\nSELECT * FROM authors\nWHERE author_id = ?;\n\n/* name: GetBook :one */\nSELECT * FROM books\nWHER"
},
{
"path": "examples/booktest/mysql/query.sql.go",
"chars": 4888,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage booktest\n\nimport (\n"
},
{
"path": "examples/booktest/mysql/schema.sql",
"chars": 853,
"preview": "CREATE TABLE authors (\n author_id integer NOT NULL AUTO_INCREMENT PRIMARY KEY,\n name text NOT NULL\n) E"
},
{
"path": "examples/booktest/postgresql/db.go",
"chars": 570,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage booktest\n\nimport (\n\t\"context\"\n\n\t\"github."
},
{
"path": "examples/booktest/postgresql/db_test.go",
"chars": 3623,
"preview": "//go:build examples\n\npackage booktest\n\nimport (\n\t\"context\"\n\t\"testing\"\n\t\"time\"\n\n\t\"github.com/jackc/pgx/v5\"\n\t\"github.com/j"
},
{
"path": "examples/booktest/postgresql/models.go",
"chars": 1259,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage booktest\n\nimport (\n\t\"database/sql/driver"
},
{
"path": "examples/booktest/postgresql/query.sql",
"chars": 989,
"preview": "-- name: GetAuthor :one\nSELECT * FROM authors\nWHERE author_id = $1;\n\n-- name: GetBook :one\nSELECT * FROM books\nWHERE boo"
},
{
"path": "examples/booktest/postgresql/query.sql.go",
"chars": 4978,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage booktest\n\nimport (\n"
},
{
"path": "examples/booktest/postgresql/schema.sql",
"chars": 908,
"preview": "CREATE TABLE authors (\n author_id SERIAL PRIMARY KEY,\n name text NOT NULL DEFAULT ''\n);\n\nCREATE INDEX "
},
{
"path": "examples/booktest/sqlc.json",
"chars": 1095,
"preview": "{\n \"version\": \"1\",\n \"cloud\": {\n \"project\": \"01HAQMMECEYQYKFJN8MP16QC41\"\n },\n \"packages\": [\n {\n \"name\": \"b"
},
{
"path": "examples/booktest/sqlite/db.go",
"chars": 601,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage booktest\n\nimport (\n\t\"context\"\n\t\"database"
},
{
"path": "examples/booktest/sqlite/db_test.go",
"chars": 3321,
"preview": "//go:build examples\n\npackage booktest\n\nimport (\n\t\"context\"\n\t\"testing\"\n\t\"time\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/sqlte"
},
{
"path": "examples/booktest/sqlite/models.go",
"chars": 332,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage booktest\n\nimport (\n\t\"time\"\n)\n\ntype Autho"
},
{
"path": "examples/booktest/sqlite/query.sql",
"chars": 1037,
"preview": "/* name: GetAuthor :one */\nSELECT * FROM authors\nWHERE author_id = ?;\n\n/* name: GetBook :one */\nSELECT * FROM books\nWHER"
},
{
"path": "examples/booktest/sqlite/query.sql.go",
"chars": 5521,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query.sql\n\npackage booktest\n\nimport (\n"
},
{
"path": "examples/booktest/sqlite/schema.sql",
"chars": 690,
"preview": "CREATE TABLE authors (\n author_id integer NOT NULL PRIMARY KEY AUTOINCREMENT,\n name text NOT NULL\n);\n\n"
},
{
"path": "examples/jets/README.md",
"chars": 141,
"preview": "This database schema and query selection is taken from the\n[SQLBoiler](https://github.com/volatiletech/sqlboiler#feature"
},
{
"path": "examples/jets/postgresql/db.go",
"chars": 566,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage jets\n\nimport (\n\t\"context\"\n\n\t\"github.com/"
},
{
"path": "examples/jets/postgresql/models.go",
"chars": 357,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage jets\n\ntype Jet struct {\n\tID int32\n\t"
},
{
"path": "examples/jets/postgresql/query-building.sql",
"chars": 174,
"preview": "-- name: CountPilots :one\nSELECT COUNT(*) FROM pilots;\n\n-- name: ListPilots :many\nSELECT * FROM pilots LIMIT 5;\n\n-- name"
},
{
"path": "examples/jets/postgresql/query-building.sql.go",
"chars": 1089,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: query-building.sql\n\npackage jets\n\nimpo"
},
{
"path": "examples/jets/postgresql/schema.sql",
"chars": 1142,
"preview": "CREATE TABLE pilots (\n id integer NOT NULL,\n name text NOT NULL\n);\n\nALTER TABLE pilots ADD CONSTRAINT "
},
{
"path": "examples/jets/sqlc.json",
"chars": 505,
"preview": "{\n \"version\": \"1\",\n \"cloud\": {\n \"project\": \"01HAQMMECEYQYKFJN8MP16QC41\"\n },\n \"packages\": [\n {\n \"path\": \"p"
},
{
"path": "examples/ondeck/mysql/city.sql.go",
"chars": 1722,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: city.sql\n\npackage ondeck\n\nimport (\n\t\"c"
},
{
"path": "examples/ondeck/mysql/db.go",
"chars": 5773,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/s"
},
{
"path": "examples/ondeck/mysql/db_test.go",
"chars": 3207,
"preview": "//go:build examples\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"strings\"\n\t\"testing\"\n\n\t_ \"github.com/go-sql-dr"
},
{
"path": "examples/ondeck/mysql/models.go",
"chars": 1768,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"database/sql\"\n\t\"datab"
},
{
"path": "examples/ondeck/mysql/querier.go",
"chars": 833,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/s"
},
{
"path": "examples/ondeck/mysql/query/city.sql",
"chars": 296,
"preview": "/* name: ListCities :many */\nSELECT *\nFROM city\nORDER BY name;\n\n/* name: GetCity :one */\nSELECT *\nFROM city\nWHERE slug ="
},
{
"path": "examples/ondeck/mysql/query/venue.sql",
"chars": 643,
"preview": "/* name: ListVenues :many */\nSELECT *\nFROM venue\nWHERE city = ?\nORDER BY name;\n\n/* name: DeleteVenue :exec */\nDELETE FRO"
},
{
"path": "examples/ondeck/mysql/schema/0001_city.sql",
"chars": 81,
"preview": "CREATE TABLE city (\n slug varchar(255) PRIMARY KEY,\n name text NOT NULL\n);\n"
},
{
"path": "examples/ondeck/mysql/schema/0002_venue.sql",
"chars": 587,
"preview": "CREATE TABLE venues (\n id SERIAL primary key,\n dropped text,\n status ENUM('ope"
},
{
"path": "examples/ondeck/mysql/schema/0003_add_column.sql",
"chars": 149,
"preview": "ALTER TABLE venues RENAME TO venue;\nALTER TABLE venue ADD COLUMN created_at TIMESTAMP NOT NULL DEFAULT NOW();\nALTER TABL"
},
{
"path": "examples/ondeck/mysql/venue.sql.go",
"chars": 3960,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: venue.sql\n\npackage ondeck\n\nimport (\n\t\""
},
{
"path": "examples/ondeck/postgresql/city.sql.go",
"chars": 1920,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: city.sql\n\npackage ondeck\n\nimport (\n\t\"c"
},
{
"path": "examples/ondeck/postgresql/db.go",
"chars": 5773,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/s"
},
{
"path": "examples/ondeck/postgresql/db_test.go",
"chars": 2836,
"preview": "//go:build examples\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"testing\"\n\n\t\"github.com/google/go-cmp/cmp\"\n\t_ "
},
{
"path": "examples/ondeck/postgresql/models.go",
"chars": 1659,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"database/sql\"\n\t\"datab"
},
{
"path": "examples/ondeck/postgresql/querier.go",
"chars": 937,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"context\"\n)\n\ntype Quer"
},
{
"path": "examples/ondeck/postgresql/query/city.sql",
"chars": 413,
"preview": "-- name: ListCities :many\nSELECT *\nFROM city\nORDER BY name;\n\n-- name: GetCity :one\nSELECT *\nFROM city\nWHERE slug = $1;\n\n"
},
{
"path": "examples/ondeck/postgresql/query/venue.sql",
"chars": 657,
"preview": "-- name: ListVenues :many\nSELECT *\nFROM venue\nWHERE city = $1\nORDER BY name;\n\n-- name: DeleteVenue :exec\nDELETE FROM ven"
},
{
"path": "examples/ondeck/postgresql/schema/0001_city.sql",
"chars": 72,
"preview": "CREATE TABLE city (\n slug text PRIMARY KEY,\n name text NOT NULL\n)\n"
},
{
"path": "examples/ondeck/postgresql/schema/0002_venue.sql",
"chars": 675,
"preview": "CREATE TYPE status AS ENUM ('op!en', 'clo@sed');\nCOMMENT ON TYPE status IS 'Venues can be either open or closed';\n\nCREAT"
},
{
"path": "examples/ondeck/postgresql/schema/0003_add_column.sql",
"chars": 149,
"preview": "ALTER TABLE venues RENAME TO venue;\nALTER TABLE venue ADD COLUMN created_at TIMESTAMP NOT NULL DEFAULT NOW();\nALTER TABL"
},
{
"path": "examples/ondeck/postgresql/venue.sql.go",
"chars": 3996,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: venue.sql\n\npackage ondeck\n\nimport (\n\t\""
},
{
"path": "examples/ondeck/sqlc.json",
"chars": 1354,
"preview": "{\n \"version\": \"1\",\n \"cloud\": {\n \"project\": \"01HAQMMECEYQYKFJN8MP16QC41\"\n },\n \"packages\": [\n {\n \"path\": \"p"
},
{
"path": "examples/ondeck/sqlite/city.sql.go",
"chars": 1722,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: city.sql\n\npackage ondeck\n\nimport (\n\t\"c"
},
{
"path": "examples/ondeck/sqlite/db.go",
"chars": 5773,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/s"
},
{
"path": "examples/ondeck/sqlite/db_test.go",
"chars": 3170,
"preview": "//go:build examples\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"strings\"\n\t\"testing\"\n\n\t\"github.com/sqlc-dev/sq"
},
{
"path": "examples/ondeck/sqlite/models.go",
"chars": 711,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"database/sql\"\n\t\"time\""
},
{
"path": "examples/ondeck/sqlite/querier.go",
"chars": 833,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n\npackage ondeck\n\nimport (\n\t\"context\"\n\t\"database/s"
},
{
"path": "examples/ondeck/sqlite/query/city.sql",
"chars": 296,
"preview": "/* name: ListCities :many */\nSELECT *\nFROM city\nORDER BY name;\n\n/* name: GetCity :one */\nSELECT *\nFROM city\nWHERE slug ="
},
{
"path": "examples/ondeck/sqlite/query/venue.sql",
"chars": 655,
"preview": "/* name: ListVenues :many */\nSELECT *\nFROM venue\nWHERE city = ?\nORDER BY name;\n\n/* name: DeleteVenue :exec */\nDELETE FRO"
},
{
"path": "examples/ondeck/sqlite/schema/0001_city.sql",
"chars": 80,
"preview": "CREATE TABLE city (\n slug varchar(255) PRIMARY KEY,\n name text NOT NULL\n)\n"
},
{
"path": "examples/ondeck/sqlite/schema/0002_venue.sql",
"chars": 494,
"preview": "CREATE TABLE venues (\n id integer primary key AUTOINCREMENT,\n dropped text,\n status "
},
{
"path": "examples/ondeck/sqlite/schema/0003_add_column.sql",
"chars": 160,
"preview": "ALTER TABLE venues RENAME TO venue;\nALTER TABLE venue ADD COLUMN created_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP;"
},
{
"path": "examples/ondeck/sqlite/venue.sql.go",
"chars": 3972,
"preview": "// Code generated by sqlc. DO NOT EDIT.\n// versions:\n// sqlc v1.30.0\n// source: venue.sql\n\npackage ondeck\n\nimport (\n\t\""
},
{
"path": "go.mod",
"chars": 2773,
"preview": "module github.com/sqlc-dev/sqlc\n\ngo 1.26.0\n\nrequire (\n\tgithub.com/antlr4-go/antlr/v4 v4.13.1\n\tgithub.com/cubicdaiya/gonp"
},
{
"path": "go.sum",
"chars": 29603,
"preview": "cel.dev/expr v0.25.1 h1:1KrZg61W6TWSxuNZ37Xy49ps13NUovb66QLprthtwi4=\ncel.dev/expr v0.25.1/go.mod h1:hrXvqGP6G6gyx8UAHSHJ"
},
{
"path": "internal/analysis/analysis.pb.go",
"chars": 18712,
"preview": "// Code generated by protoc-gen-go. DO NOT EDIT.\n// versions:\n// \tprotoc-gen-go v1.30.0\n// \tprotoc (unknown)\n// s"
},
{
"path": "internal/analysis/analysis_vtproto.pb.go",
"chars": 41931,
"preview": "// Code generated by protoc-gen-go-vtproto. DO NOT EDIT.\n// protoc-gen-go-vtproto version: v0.4.0\n// source: analysis/an"
},
{
"path": "internal/analyzer/analyzer.go",
"chars": 3479,
"preview": "package analyzer\n\nimport (\n\t\"context\"\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"hash/fnv\"\n\t\"log/slog\"\n\t\"os\"\n\t\"path/filepath\"\n\n\t\"google.g"
},
{
"path": "internal/bundler/multipart.go",
"chars": 727,
"preview": "package bundler\n\nimport (\n\t\"os\"\n\t\"path/filepath\"\n\n\tpb \"github.com/sqlc-dev/sqlc/internal/quickdb/v1\"\n\t\"github.com/sqlc-d"
},
{
"path": "internal/bundler/upload.go",
"chars": 4303,
"preview": "package bundler\n\nimport (\n\t\"context\"\n\t\"errors\"\n\t\"fmt\"\n\t\"log/slog\"\n\t\"os\"\n\t\"strings\"\n\n\t\"google.golang.org/protobuf/proto\"\n"
},
{
"path": "internal/cache/cache.go",
"chars": 1105,
"preview": "package cache\n\nimport (\n\t\"fmt\"\n\t\"os\"\n\t\"path/filepath\"\n)\n\n// The cache directory defaults to os.UserCacheDir(). This loca"
},
{
"path": "internal/cmd/cmd.go",
"chars": 7373,
"preview": "package cmd\n\nimport (\n\t\"bufio\"\n\t\"bytes\"\n\t\"context\"\n\t\"errors\"\n\t\"fmt\"\n\t\"io\"\n\t\"os\"\n\t\"os/exec\"\n\t\"path/filepath\"\n\t\"runtime/tr"
},
{
"path": "internal/cmd/createdb.go",
"chars": 2586,
"preview": "package cmd\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\t\"os\"\n\t\"runtime/trace\"\n\t\"time\"\n\n\t\"github.com/spf13/cobra\"\n\t\"github.com/sqlc-dev/"
},
{
"path": "internal/cmd/diff.go",
"chars": 1253,
"preview": "package cmd\n\nimport (\n\t\"context\"\n\t\"errors\"\n\t\"fmt\"\n\t\"os\"\n\t\"runtime/trace\"\n\t\"sort\"\n\t\"strings\"\n\n\t\"github.com/cubicdaiya/gon"
},
{
"path": "internal/cmd/generate.go",
"chars": 11177,
"preview": "package cmd\n\nimport (\n\t\"context\"\n\t\"encoding/json\"\n\t\"errors\"\n\t\"fmt\"\n\t\"io\"\n\t\"os\"\n\t\"path/filepath\"\n\t\"runtime/trace\"\n\t\"strin"
},
{
"path": "internal/cmd/options.go",
"chars": 534,
"preview": "package cmd\n\nimport (\n\t\"io\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/config\"\n)\n\ntype Options struct {\n\tEnv Env\n\tStderr io"
},
{
"path": "internal/cmd/parse.go",
"chars": 2636,
"preview": "package cmd\n\nimport (\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"io\"\n\t\"os\"\n\n\t\"github.com/spf13/cobra\"\n\n\t\"github.com/sqlc-dev/sqlc/interna"
},
{
"path": "internal/cmd/process.go",
"chars": 3070,
"preview": "package cmd\n\nimport (\n\t\"bytes\"\n\t\"context\"\n\t\"fmt\"\n\t\"io\"\n\t\"path/filepath\"\n\t\"runtime\"\n\t\"runtime/trace\"\n\n\t\"golang.org/x/sync"
},
{
"path": "internal/cmd/push.go",
"chars": 2100,
"preview": "package cmd\n\nimport (\n\t\"context\"\n\t\"fmt\"\n\t\"os\"\n\t\"sync\"\n\n\t\"github.com/spf13/cobra\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/bu"
},
{
"path": "internal/cmd/shim.go",
"chars": 5475,
"preview": "package cmd\n\nimport (\n\t\"github.com/sqlc-dev/sqlc/internal/compiler\"\n\t\"github.com/sqlc-dev/sqlc/internal/config\"\n\t\"github"
},
{
"path": "internal/cmd/verify.go",
"chars": 3855,
"preview": "package cmd\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"errors\"\n\t\"fmt\"\n\t\"log/slog\"\n\t\"os\"\n\n\t_ \"github.com/jackc/pgx/v5/stdlib\""
},
{
"path": "internal/cmd/vet.go",
"chars": 17949,
"preview": "package cmd\n\nimport (\n\t\"context\"\n\t\"database/sql\"\n\t\"encoding/json\"\n\t\"errors\"\n\t\"fmt\"\n\t\"github.com/sqlc-dev/sqlc/internal/c"
},
{
"path": "internal/cmd/vet_sqlite.go",
"chars": 107,
"preview": "package cmd\n\nimport (\n\t_ \"github.com/ncruces/go-sqlite3/driver\"\n\t_ \"github.com/ncruces/go-sqlite3/embed\"\n)\n"
},
{
"path": "internal/codegen/golang/driver.go",
"chars": 312,
"preview": "package golang\n\nimport \"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\nfunc parseDriver(sqlPackage string) opts"
},
{
"path": "internal/codegen/golang/enum.go",
"chars": 1262,
"preview": "package golang\n\nimport (\n\t\"strings\"\n\t\"unicode\"\n)\n\ntype Constant struct {\n\tName string\n\tType string\n\tValue string\n}\n\nty"
},
{
"path": "internal/codegen/golang/field.go",
"chars": 2828,
"preview": "package golang\n\nimport (\n\t\"fmt\"\n\t\"regexp\"\n\t\"sort\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t"
},
{
"path": "internal/codegen/golang/gen.go",
"chars": 10479,
"preview": "package golang\n\nimport (\n\t\"bufio\"\n\t\"bytes\"\n\t\"context\"\n\t\"errors\"\n\t\"fmt\"\n\t\"go/format\"\n\t\"strings\"\n\t\"text/template\"\n\n\t\"githu"
},
{
"path": "internal/codegen/golang/go_type.go",
"chars": 2370,
"preview": "package golang\n\nimport (\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\"github.com/sqlc-dev/sqlc"
},
{
"path": "internal/codegen/golang/imports.go",
"chars": 13239,
"preview": "package golang\n\nimport (\n\t\"fmt\"\n\t\"sort\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\"github.co"
},
{
"path": "internal/codegen/golang/mysql_type.go",
"chars": 3052,
"preview": "package golang\n\nimport (\n\t\"log\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\"github.com/sqlc-dev/sqlc/int"
},
{
"path": "internal/codegen/golang/opts/enum.go",
"chars": 1512,
"preview": "package opts\n\nimport \"fmt\"\n\ntype SQLDriver string\n\nconst (\n\tSQLPackagePGXV4 string = \"pgx/v4\"\n\tSQLPackagePGXV5 str"
},
{
"path": "internal/codegen/golang/opts/go_type.go",
"chars": 4794,
"preview": "package opts\n\nimport (\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"go/types\"\n\t\"regexp\"\n\t\"strings\"\n\n\t\"github.com/fatih/structtag\"\n)\n\ntype G"
},
{
"path": "internal/codegen/golang/opts/options.go",
"chars": 6745,
"preview": "package opts\n\nimport (\n\t\"encoding/json\"\n\t\"fmt\"\n\t\"maps\"\n\t\"path/filepath\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/plugin\"\n)\n\n"
},
{
"path": "internal/codegen/golang/opts/override.go",
"chars": 5343,
"preview": "package opts\n\nimport (\n\t\"fmt\"\n\t\"os\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/sdk\"\n\t\"github.com/sqlc-dev/s"
},
{
"path": "internal/codegen/golang/opts/override_test.go",
"chars": 2429,
"preview": "package opts\n\nimport (\n\t\"testing\"\n\n\t\"github.com/google/go-cmp/cmp\"\n)\n\nfunc TestTypeOverrides(t *testing.T) {\n\tfor _, tes"
},
{
"path": "internal/codegen/golang/opts/shim.go",
"chars": 1952,
"preview": "package opts\n\nimport (\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/plugin\"\n)\n\n// The ShimOverride struct exists to b"
},
{
"path": "internal/codegen/golang/postgresql_type.go",
"chars": 12228,
"preview": "package golang\n\nimport (\n\t\"fmt\"\n\t\"log\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\"github.com"
},
{
"path": "internal/codegen/golang/query.go",
"chars": 6920,
"preview": "package golang\n\nimport (\n\t\"fmt\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\"github.com/sqlc-d"
},
{
"path": "internal/codegen/golang/reserved.go",
"chars": 929,
"preview": "package golang\n\nfunc escape(s string) string {\n\tif IsReserved(s) {\n\t\treturn s + \"_\"\n\t}\n\treturn s\n}\n\nfunc IsReserved(s st"
},
{
"path": "internal/codegen/golang/result.go",
"chars": 11430,
"preview": "package golang\n\nimport (\n\t\"bufio\"\n\t\"fmt\"\n\t\"sort\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\""
},
{
"path": "internal/codegen/golang/result_test.go",
"chars": 1324,
"preview": "package golang\n\nimport (\n\t\"testing\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/metadata\"\n\t\"github.com/sqlc-dev/sqlc/internal/p"
},
{
"path": "internal/codegen/golang/sqlite_type.go",
"chars": 1986,
"preview": "package golang\n\nimport (\n\t\"log\"\n\t\"strings\"\n\n\t\"github.com/sqlc-dev/sqlc/internal/codegen/golang/opts\"\n\t\"github.com/sqlc-d"
}
]
// ... and 6471 more files (download for full content)
About this extraction
This page contains the full source code of the sqlc-dev/sqlc GitHub repository, extracted and formatted as plain text for AI agents and large language models (LLMs). The extraction includes 6671 files (12.3 MB), approximately 3.7M tokens, and a symbol index with 17482 extracted functions, classes, methods, constants, and types. Use this with OpenClaw, Claude, ChatGPT, Cursor, Windsurf, or any other AI tool that accepts text input. You can copy the full output to your clipboard or download it as a .txt file.
Extracted by GitExtract — free GitHub repo to text converter for AI. Built by Nikandr Surkov.