Re: Changing pg_dump default file format

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Changing pg_dump default file format
Date: 2013-11-07 16:10:15
Message-ID: CABUevExKPG8UccqdG0HGeW7Wmkgmx8bd8MkW7V=dsggYHW4vvg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Nov 7, 2013 at 5:02 PM, Joshua D. Drake <jd(at)commandprompt(dot)com> wrote:
>
> Hello,
>
> For as long as I can remember I have heard complaints about the fact that
> pg_dump doesn't use a backup format that is supported by the pg_restore
> program. At every single talk that I give that talks about pg_dump, the
> people in the majority of the audience agrees that this is rather silly and
> a barrier to usability.
>
> The only counter argument I have heard is that it adds an extra step for
> developers to get the SQL that generates a database. That to me is a weak
> argument as pg_dump is a production/admin too, first, not a developer tool.
>
> I humbly request on behalf of those who manage production postgresql
> instances that we change the default backup file format from -Fp to -Fc.

The main reason for keeping plain I guess goes with the fact that we
sent it to stdout by default, which really doesn't lend itself to the
custom format.

I'm a bit worried about it breaking peoples scripts as well, if they
pipe the output. In particular when doing a partial dump of say a
sigle table or such, and in my experience that's mostly done in
pipe-mode, which would break.

Though I have to say I like the idea in general :)

Maybe we could consider changing the default format if -f is specified
to write it directly to a file. OTOH, hat might just make it
confusing....

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2013-11-07 16:17:06 Re: Changing pg_dump default file format
Previous Message Joshua D. Drake 2013-11-07 16:02:13 Changing pg_dump default file format