Re: Nested xacts: looking for testers and review

From: Jan Wieck <JanWieck(at)Yahoo(dot)com>
To: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Tatsuo Ishii <t-ishii(at)sra(dot)co(dot)jp>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Nested xacts: looking for testers and review
Date: 2004-05-31 13:12:10
Message-ID: 40BB2F2A.6070104@Yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 5/28/2004 2:52 PM, Alvaro Herrera wrote:

> On Fri, May 28, 2004 at 01:43:16PM -0400, Bruce Momjian wrote:
>
>> In this case, I want to try all of the inserts, but any of them can
>> fail, then I want the bottom part done.
>
> I wonder where everyone eas when I asked this question a lot of time
> ago. I said I thought the behavior should be like I described, and no
> one objected.
>
> Personally I think it would be a mistake to allow the COMMIT for the
> subtransaction to ignore the fact that the subxact was aborted. However
> I realize what you are proposing, and maybe this can be implemented
> using a parameter to COMMIT (indicating to not propagate the error if
> it's in aborted state, but commit normally otherwise).

I agree on this one. Subtransactions are a feature to add more fine
control to applications, not to ignore error checking for scripting.

>
> However if everyone disagrees, I can take that part out, and the code
> would be simpler. IMHO however, it would be less reliable.

Please don't.

Jan

--
#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me. #
#================================================== JanWieck(at)Yahoo(dot)com #

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Teodor Sigaev 2004-05-31 13:32:56 Re: yet another contrib module
Previous Message Bruce Momjian 2004-05-31 13:11:42 Re: Converting postgresql.conf parameters to kilobytes