Re: Shouldn't psql -1 imply ON_ERROR_STOP?

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Magnus Hagander <magnus(at)hagander(dot)net>
Cc: Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Shouldn't psql -1 imply ON_ERROR_STOP?
Date: 2009-07-25 13:15:39
Message-ID: 603c8f070907250615u2c728f46y18ddfc5cc25314cd@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Jul 25, 2009 at 9:06 AM, Magnus Hagander<magnus(at)hagander(dot)net> wrote:
> On Saturday, July 25, 2009, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
>> When you run a file with psql -1/--single-transaction, and a command fails,
>> you get bombarded with
>>
>> ERROR:  current transaction is aborted, commands ignored until end of
>> transaction block
>>
>> for the rest of the file.
>>
>
> That would certainly be useful.
>
> Personally I'd prefer it to default to that always, and not just in
> -1, but that would break way too many old things I'm afraid...

Doing it always would be really annoying. I often reload dumps that
fail the grant statements but otherwise work. Admittedly, if I
planned ahead, I could avoid having the grants be present in the
dumps, but that would require planning ahead...

But +1 for doing it when -1 is used.

...Robert

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Merlin Moncure 2009-07-25 14:15:02 Re: proposal: support empty string as separator for string_to_array
Previous Message Magnus Hagander 2009-07-25 13:06:44 Re: Shouldn't psql -1 imply ON_ERROR_STOP?