Skip to content

Instantly share code, notes, and snippets.

@brenogcota
Last active November 13, 2021 14:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brenogcota/5c5215eb94e86104a587a7afd942ca55 to your computer and use it in GitHub Desktop.
Save brenogcota/5c5215eb94e86104a587a7afd942ca55 to your computer and use it in GitHub Desktop.
basic psql commands

sudo -u user psql database

connect database

\c database

show seq schemas

\d

show schemas

\dt

show data

SELECT * FROM "public".users;

exit

exit or \q

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment