If I give `prisma` a postgres connection string wi...
# orm-help
a
If I give
prisma
a postgres connection string with a schema that doesn't exist, it should create it correct?
d
as long as it has valid permissions on the user its authenticating as, yes
a
Using postgres 12.7 if I use a postgres connection string
<postgresql://postgres:postgres@localhost:5432/dev?schema=newSchema>
I get an error which doesn't have much info (see image) If I use
currentSchema
instead of
schema
it falls back to the
public
schema
wait, maybe not
actually yea, using
schema
will cause prisma to create the schema, but when I try to run any migration command on it it fails with
Copy code
Error querying the database: db error: ERROR: current transaction is aborted, commands ignored until end of transaction block
       0: migration_core::api::ApplyMigrations
                 at migration-engine/core/src/api.rs:69
oooh i guess its somethign with the shadow db permissions issue, I thought this was fixed (im on 2.26 of the prisma cli)
j
If there is no issue for this yet, please create one.
a
I'm trying to find the previous github issue that I think was focused around heroku, I know that was a big thing a ways back due to a permissions issue for creating the shadow db, but then I saw it was fixed. I want to make sure that there isn't something I have to do in postgres to set correct permissions first, then I'll create an issue. But for now using
db push
works well
actually, i prefer it over migrate because I don't want the seed file torun