Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save dallasmarlow/e135d305d654b83207df161e3344d24e to your computer and use it in GitHub Desktop.
Save dallasmarlow/e135d305d654b83207df161e3344d24e to your computer and use it in GitHub Desktop.
postgres commands
createdb <db name>
psql postgres
psql <db name>
\conninfo
You are connected to database "postgres" as user "dallasmarlow" via socket in "/tmp" at port "5432".
\du
List of roles
Role name | Attributes | Member of
--------------+------------------------------------------------------------+-----------
dallasmarlow | Superuser, Create role, Create DB, Replication, Bypass RLS | {}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment