Difference between revisions of "Psql"

From wikieduonline
Jump to navigation Jump to search
Line 30: Line 30:
 
* <code>[[pg_hba.conf]]</code> (PostgreSQL Client Authentication Configuration File)
 
* <code>[[pg_hba.conf]]</code> (PostgreSQL Client Authentication Configuration File)
 
* <code>[[apt install postgresql]]</code>
 
* <code>[[apt install postgresql]]</code>
 +
* {{TOC operation databases}}
  
 
== See also ==
 
== See also ==

Revision as of 07:46, 26 February 2021


psql
psql: FATAL:  role "root" does not exist
sudo -u postgres psql
psql (10.12 (Ubuntu 10.12-0ubuntu0.18.04.1))
Type "help" for help.
postgres=#
su - posgres && psql
psql (10.12 (Ubuntu 10.12-0ubuntu0.18.04.1))
Type "help" for help.
postgres=#
sudo -u postgres psql
could not change directory to "/root": Permission denied
psql (12.6 (Ubuntu 12.6-0ubuntu0.20.04.1))
Type "help" for help.


psql -h localhost -U YOUR_USERNAME DB_NAME


Options

  • Port (-p): psql -p 5432

Related terms

See also

Advertising: