prisma can't connect to postgres database "user was denied access"
prisma can't connect to my local postgresql database even though the user I connect with is the owner of the database...
27 Replies
.env file:
proof this user can actually connect to the db:
if anyone can help quickly
I've been stuck on this for a week
Your connection string should look something like:
Can you try this format?
It looked like password field was missing in your connection string
that's because it had no password
@Nurul (Prisma) for the sake of argument, is there some command I can use to get the password for this user?
or is it just the login password for the user on the system
I mean is the users's password on postgresql the same as system login pass or different
because I didn't set a specific password for this user in postgres
You'll want to set a password for that user
how can I do that
ALTER USER user_name WITH PASSWORD 'new_password';
It's recommended to have a password, can you try setting the password with the above SQL command and pass it in the connection string and check?
Let us know in case you still get the same error.
same error 😩
@Nurul (Prisma) @Yetzederixx
I just tried this
also doesn't work
Are you able to connect to this database via a GUI tool like TablePlus or PgAdmin?
I have a feeling that user may not actually have permissions on the table
and/or db if you have multiple db's on the server
Stack Overflow
PostgreSQL: Show all the privileges for a concrete user
How to make a query to the Postgres data dictionary to find out all the privileges that a particular user has.
I've been looking for a solution and I can not find anything. Thanks and good day
I think I do have permissions
I don't have any gui tools but I can connect to it using psql like this:
the schema permissions line from the stack overflow post shows nothing though
I strongly recommend this tool for db administration.
https://dbeaver.io/download/