'Unable to login with newly created user in PostgreSQL
I am unable to login with a newly created user in PostgreSQL 14. I execute the following commands in my command prompt
psql -U postgres
then i enter my password and then see this
psql (14.1)
WARNING: Console code page (437) differs from Windows code page (1252)
8-bit characters might not work correctly. See psql reference
page "Notes for Windows users" for details.
Type "help" for help.
after this I enter
create user admin1 with encrypted password 'admin1';
after this when I close the command prompt and try to login
psql -U admin1
and enter the password, it gives me the following error
psql: error: connection to server at "localhost" (::1), port 5432 failed: FATAL: database "admin1" does not exist
I dont know why this error occurs and why it considers my 'admin1' user as a database
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
