Ravi,
To (attempt to) answer your questions:
1) does the custom archive format of pg_dump needs to be in a file (not
pipe) for the pg_restore to seek back forth ?
Not to my knowledge.
I suspect that the windows type command is adding extra header
information to the file before
...@postgresql.org] On Behalf Of Kevin Grittner
Sent: 29 March 2011 18:41
To: Ravi Thati; pgsql-admin@postgresql.org
Subject: Re: [ADMIN] pg_restore on windows with pipe
Ravi Thati gototh...@gmail.com wrote:
type C:\testdump | pg_restore -Fc [...]
pg_restore: [custom archiver] *could not find block
the form sometimes.
M
-Original Message-
From: pgsql-admin-ow...@postgresql.org
[mailto:pgsql-admin-ow...@postgresql.org] On Behalf Of Kevin Grittner
Sent: 29 March 2011 18:41
To: Ravi Thati; pgsql-admin@postgresql.org
Subject: Re: [ADMIN] pg_restore on windows with pipe
Ravi Thati
Hi All,
I am trying to restore a dump (custom archive format) using pg_restore like
this:
type C:\testdump | pg_restore -Fc -C -U postgres -w -d postgres
where testdump contains the database dump from the following commmand:
pg_dump -U postgres -Fc test C:\testdump
*the restore command
Ravi Thati gototh...@gmail.com wrote:
type C:\testdump | pg_restore -Fc [...]
pg_restore: [custom archiver] *could not find block ID 1770* in
archive -- possibly corrupt archive
pg_restore: *** aborted because of error
Does the type command treat the stream as characters? (You could
try