Re: dump-restore only one table - Mailing list pgsql-general

From Richard Huxton
Subject Re: dump-restore only one table
Date
Msg-id 46371962.4000904@archonet.com
Whole thread Raw
In response to dump-restore only one table  (Alexander Kuprijanov <sanya-spb@list.ru>)
Responses Re: dump-restore only one table
List pgsql-general
Alexander Kuprijanov wrote:
> I do:
> ==============
> pg_dump -d BaseA --port=54321 --host=localhost --table=TableA --data-only -F
> c -v | pg_restore -d
> BaseB --data-only --no-owner --table=TableA --single-transaction -v
> ==============

> But <BaseB.TableA> wasn't updated.... why??

I'm not sure you can pipe the custom format between pg_dump and
pg_restore (it's got compressed sections). Either:
1. Use a temporary file
2. pipe the standard format to psql

--
   Richard Huxton
   Archonet Ltd

pgsql-general by date:

Previous
From: Alexander Kuprijanov
Date:
Subject: dump-restore only one table
Next
From: Martijn van Oosterhout
Date:
Subject: Re: [HACKERS] SOS, help me please, one problem towards the postgresql developement on windows