Re: Option to dump foreign data in pg_dump

Luis Carril <luis.carril@swarm64.com>

From: Luis Carril <luis.carril@swarm64.com>
To: Daniel Gustafsson <daniel@yesql.se>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2019-07-12T14:08:28Z
Lists: pgsql-hackers

Attachments

> > On 28 Jun 2019, at 19:55, Luis Carril <luis.carril@swarm64.com> wrote:
> > What about providing a list of FDW servers instead of an all or nothing option? In that way the user really has to do a conscious decision to dump the content of the foreign tables for > > a specific server, this would allow distinction if multiple FDW are being used in the same DB.

> I think this is a good option, the normal exclusion rules can then still apply
> in case not everything from a specific server is of interest.

Hi, here  is a new patch to dump the data of foreign tables using pg_dump.
This time the user specifies for which foreign servers the data will be dumped, which helps in case of having a mix of writeable and non-writeable fdw in the database.
It would be nice to emit an error if the fdw is read-only, but that information is not available in the catalog.

Cheers
Luis M Carril

Commits

  1. pg_dump: Allow dumping data of specific foreign servers