Created
November 19, 2020 03:16
-
-
Save raymzag/40925c4f0fe7638ba1f3b6a7a3e3ef0d to your computer and use it in GitHub Desktop.
useful psql commands
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# pg_dump | |
pg_dump -h localhost -p 5432 -U postgres -d my_db -x -O -Fc > my_db.dump | |
# pg_restore | |
pg_restore -h localhost -p 5432 -U postgres -d my_db -x -O -c -j 4 my_db.dump |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment