You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I work with Postgres. I use init script to provision a database, a non-admin user and non-public schema. Everything else (tables, triggers etc.) is done in migrations. All migrations reference tables using a schema. I used to have this "init" script as the first migration but now for certain reasons it moved out.
sqlc vet (using a local/docker DB) used to work correctly back then, but now when migration is out, it reports "Schema <xyz> does not exist" on every migration file. After a lot of debugging, I found a hotfix to add CREATE SCHEMA IF NOT EXISTS xyz; before running sqlc vet to a "fake" first migration (and delete it afterwards).
Would be great if it worked without that workaround..
Version
1.27.0
What happened?
Hi
Thank you for developing sqlc!
I work with Postgres. I use init script to provision a database, a non-admin user and non-public schema. Everything else (tables, triggers etc.) is done in migrations. All migrations reference tables using a schema. I used to have this "init" script as the first migration but now for certain reasons it moved out.
sqlc vet
(using a local/docker DB) used to work correctly back then, but now when migration is out, it reports"Schema <xyz> does not exist"
on every migration file. After a lot of debugging, I found a hotfix to addCREATE SCHEMA IF NOT EXISTS xyz;
before runningsqlc vet
to a "fake" first migration (and delete it afterwards).Would be great if it worked without that workaround..
Relevant log output
No response
Database schema
No response
SQL queries
No response
Configuration
Playground URL
No response
What operating system are you using?
Linux
What database engines are you using?
PostgreSQL
What type of code are you generating?
Go
The text was updated successfully, but these errors were encountered: