Tuesday 13 June 2023

Connecting to remote PostgreSQL 14 instance

 psql 'postgres://<username>:<password>@<host>:<port>/<databasename>?sslmode=disable'

Example of the above command with example username, password and database name:

psql 'postgres://myUsername1:databasePassword1@192.168.10.60:5436/database1?sslmode=disable'