pg_dump incorrect output in plaintext mode - Mailing list pgsql-hackers

From Magnus Hagander
Subject pg_dump incorrect output in plaintext mode
Date
Msg-id CABUevEyvhGBCfsHL5GkfXti4wSGBzVXgtP4fq3bZFTqAns6Zqg@mail.gmail.com
Whole thread Raw
Responses Re: pg_dump incorrect output in plaintext mode
Re: pg_dump incorrect output in plaintext mode
List pgsql-hackers
$ pg_dump -v postgres -Fc -t t > /dev/null
...
pg_dump: dumping contents of table t
...

but in plaintext:
$ pg_dump -v postgres -Fp -t t > /dev/null
pg_dump: creating TABLE t
pg_dump: restoring data for table "t"
pg_dump: dumping contents of table t
pg_dump: setting owner and privileges for TABLE t
pg_dump: setting owner and privileges for TABLE DATA t


In particular, the "restoring data" is obviously completely wrong. But
AFAICT, the "creating table" and "setting owner" etc are also wrong...

This is because pg_dump calls RestoreArchive(fout).

Do we need to pass down a parameter all the way down the functions to
tell them if they're restoring or not?


-- Magnus HaganderMe: http://www.hagander.net/Work: http://www.redpill-linpro.com/



pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: SP-GiST micro-optimizations
Next
From: Robert Haas
Date:
Subject: Re: MySQL search query is not executing in Postgres DB