Connecting to PostgreSQL
|
Change to Postgres user and open psql prompt |
|
Connect to |
Working with Databases
|
Connect to a database |
|
Backup a database |
|
Create a database |
|
Drop a database |
List Information
|
List databases |
|
List roles Think "describe users" |
|
List schemas in a connected DB |
|
List tables in a connected DB Think "describe tables" |
|
List functions in a connected DB Think "describe functions" |
|
List functions and show info (e.g. functions owner and source) in a connected DB |
|
List columns on table |
Roles and Privileges
|
Create role |
|
Alter role |
|
Drop role |
|
Grant privileges |