From: | Rob Richardson <RDRichardson(at)rad-con(dot)com> |
---|---|
To: | "pgadmin-support(at)postgresql(dot)org" <pgadmin-support(at)postgresql(dot)org> |
Subject: | Why doesn't PGAdmin support backing up of schema only or data only? |
Date: | 2014-02-07 14:32:53 |
Message-ID: | 67D108EDFAD3C148A593E6ED7DCB4BBDD83F49EF@RADCONWIN2K8PDC.radcon.local |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-support |
Greetings!
I have been curious for several years: Why doesn't PGAdmin's backup screen allow me to save data only or schema only in custom format?
I am trying to test a long-running application that uses a PostgreSQL database. I occasionally need to change or add a database function or make some other change that does not affect table structures. I also need to save backups of the database at various times as the application runs so I can restart the application from that point. In the past, if I changed a database function, I needed to open all of the database copies I've been using and apply the change to each one individually.
It occurred to me recently that if I save the data and schema separately, then I can create a database, load the latest version of the schema (with the changed function) into it, and then choose which state of data to load (beginning of the application, middle, near the end, or whatever).
With PGAdmin's backup screen, I only get a choice of data only or schema only if I select a plain format for my backup file. But then, if I use psql to restore my data, all triggers are active, and the effects of the triggers mean that the restored data is not the same as the data that was backed up. psql does not have a disable triggers options. On the other hand, pg_restore does have an option to disable triggers, ensuring that the restored data is identical to the saved data. But pg_restore only works on custom format files. PGAdmin's backup screen is merely a GUI wrapper around the pg_dump program, and with pg_dump there's no problem saving schema only or data only into custom-format files. So why doesn't PGAdmin let us do it?
Thanks very much.
RobR
From | Date | Subject | |
---|---|---|---|
Next Message | Guillaume Lelarge | 2014-02-08 17:28:09 | Re: Why doesn't PGAdmin support backing up of schema only or data only? |
Previous Message | Muhammad Rizwan Anwar | 2014-02-07 10:08:49 | Re: Restoring PostgreSQL Database Backup |