Switch database on PGSQL

To switch to another database when connect to PostgreSQL Server use following command on psql.

postgres=>\connect databasename
postgres=> \c databasename
For eg: Lets say you are connected to default postgres database and want to connect to database name mydatabase, try below syntax

postgres=> \c mydatabase or postgres=> \connect mydatabase
mydatabase=>

Comments

Popular posts from this blog

Getting Started with MariaDB

PowerShell to find HyperLink Text in PowerPoint

Drop Database in Oracle