Skip to content

Instantly share code, notes, and snippets.

@jonny-novikov
Created August 25, 2016 19:56
Show Gist options
  • Save jonny-novikov/d8ccc57326f5d3c11aacbc8560ab6b49 to your computer and use it in GitHub Desktop.
Save jonny-novikov/d8ccc57326f5d3c11aacbc8560ab6b49 to your computer and use it in GitHub Desktop.
Postgresql dump and restore
#take full dump
pg_dump -i -U user_name -F t -b -v -f "prod.backup" db_name
#restore specific table
pg_restore -i -U user_name -d db_name -t table_name -v "prod.backup"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment