Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

Don't they essentially do the same thing by storing all the data in a file and dumping it into another database? Is it that pg_dump just adds the data on to whatever is already there and restore deletes everything and then dumps it in?

share|improve this question

migrated from stackoverflow.com Mar 19 '13 at 2:03

This question came from our site for professional and enthusiast programmers.

1 Answer 1

up vote 3 down vote accepted

pg_dump is the basic official tool of the project to create backups of PostgreSQL databases (or selected objects in it) in the file system.

To restore, you can either use pg_restore or simply psql, depending on the format of the backup.

The "Backup" and "Restore" options of pgAdmin are just fronts to the above mentioned tools.

There is no (official) tool "backup" or "restore" like you seem to be implying. You are probably confusing terms.

share|improve this answer
2  
I would just add that there are other official tools which do other kinds of backups in PostgreSQL 9+. pg_basebackup is a good example. –  Chris Travers Mar 20 '13 at 9:51

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.