Re: Information on savepoint requirement within transctions

From: Melvin Davidson <melvin6925(at)gmail(dot)com>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: Robert Zenz <robert(dot)zenz(at)sibvisions(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Information on savepoint requirement within transctions
Date: 2018-01-26 16:27:21
Message-ID: CANu8Fiy-iTsuDeQ5Vq2U0TEaUTWD2+g5+rSmhEw6qv3pRz3DbA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

>

> As far as I'm aware neither PostgreSQL nor OS version do matter for this

Yes as of this date. However, that is not to say that the SQL standard (or
PostgreSQL) may change
in the _future_, such that there "may" be a "ROLLBACK TO SAVEPOINT OR
CONTINUE" after a failure,
in which case, someone else may be confused because there is no reference
to the actual PostgreSQL version.
That is why it is important to include the version "AT THE TIME OF POSTING"
so that future op's will
have a point of reference for the answer.

On Fri, Jan 26, 2018 at 11:12 AM, David G. Johnston <
david(dot)g(dot)johnston(at)gmail(dot)com> wrote:

> On Fri, Jan 26, 2018 at 8:57 AM, Robert Zenz <robert(dot)zenz(at)sibvisions(dot)com>
> wrote:
>
>> In PostgreSQL the use of savepoints is
>> required:
>>
>> start transaction
>> insert into A
>> create savepoint
>> insert into B but fail
>> rollback to savepoint
>> insert into C
>> commit
>>
>> Otherwise the transaction is, after the failed statement, in a state in
>> which it
>> can not be used anymore. Is that correct?
>
>
> ​Yes.
>
> David J.
> ​
>
>

--
*Melvin Davidson*
I reserve the right to fantasize. Whether or not you
wish to share my fantasy is entirely up to you.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David G. Johnston 2018-01-26 16:41:20 Re: Information on savepoint requirement within transctions
Previous Message David G. Johnston 2018-01-26 16:12:39 Re: Information on savepoint requirement within transctions