Connect to your cluster using psql
Suggest editsNote
You can find all of the parameters you need to connect on the portal by selecting the name of your cluster on the Clusters page and then selecting the Connect tab.
psql is the standard PostgreSQL REPL and an all-around useful tool for working with PostgreSQL databases. In addition to letting you submit SQL and view the results, it offers quite a few built-in commands for inspecting and managing the database that make light work of even complex tasks.
You can find an example of connecting to a Cloud Service cluster by way of psql right on your cluster's Overview tab on the portal. For example:
The URI is all that's necessary for psql. While you can pass each element of that URL individually (pulling the information from the Connect tab on the portal, for instance), psql will parse it out for you and prompt for the password.
In case you're unfamiliar with PostgreSQL's URI format, you can find it documented on postgresql.org.
EDB Postgres Advanced Server enhancements
If your cluster is running EDB Postgres Advanced Server, you might want to install the version of psql that ships with it. It includes a few nice additions, such as tab completion for Oracle database-compatible syntax. However, the standard PostgreSQL client works with EDB Postgres Advanced Server as well.
Further reading
For more information, see Connecting to your cluster.
- On this page
- Further reading
Could this page be better? Report a problem or suggest an addition!