views:

72

answers:

2

For Postgres is there any sort of command line utilities that allow a database to be "dumped to a file" and that allow that same database dump to be imported?

I know this can be done through PGAdmin, but I need to be able to do this on the cmd line.

+1  A: 

Correct, the way to do this is the pg_dump, pg_dumpall and pg_restore commands. In fact, I think pg_admin actually calls those commands itself. It doesn't actually have backup/restore built in but is just a wrapper.

Joshua D. Drake