snippets > basic-commands-postgresql-psql

March 01, 2020

Basic shortcuts for navigating psql command line (PostgreSQL)

psql -U $POSTGRES_USER $POSTGRES_DB
\l # list databases
\c # select a database
\d # list tables
\d+ <table_name> # describe table