Re: existence of a savepoint?

Поиск
Список
Период
Сортировка
Искать
От
Stuart McGraw
Тема
Re: existence of a savepoint?
Дата
в 01:50:58
Msg-id
66ad0952-16b1-00d8-5e0b-d4323d933340@mtneva.com
Ответ на
Список
Дерево обсуждения
existence of a savepoint? Stuart McGraw <smcg4191@mtneva.com>
Re: existence of a savepoint? Alvaro Herrera <alvherre@2ndquadrant.com>
Re: existence of a savepoint? Stuart McGraw <smcg4191@mtneva.com>
Re: existence of a savepoint? Alvaro Herrera <alvherre@2ndquadrant.com>
Re: existence of a savepoint? Stuart McGraw <smcg4191@mtneva.com>
Re: existence of a savepoint? "David G. Johnston" <david.g.johnston@gmail.com>
Re: existence of a savepoint? Stuart McGraw <smcg4191@mtneva.com>
Re: existence of a savepoint? "David G. Johnston" <david.g.johnston@gmail.com>
Re: existence of a savepoint? Brian Dunavant <brian@omniti.com>
Re: existence of a savepoint? Stuart McGraw <smcg4191@mtneva.com>
Re: existence of a savepoint? "David G. Johnston" <david.g.johnston@gmail.com>
Re: existence of a savepoint? Stuart McGraw <smcg4191@mtneva.com>
On 05/29/2018 08:26 AM, Brian Dunavant wrote:
> On Sun, May 27, 2018 at 6:04 PM, Stuart McGraw > wrote:
>     Is there some way to to test if a savepoint of a given name
>     exists?  Or better yet, the number of stacked savepoints of
>     that name?
>
> This is kind of backwards, but you can determine if a savepoint by a certain name exists by trying to release it.   You can do so without damaging the transaction by creating a savepoint immediately beforehand, but this will cause you to lose the state of the named savepoint.  Example below. 
> [...snipped for brevity...]

Thanks.  That's interesting, protecting a questionable
release with another savepoint.  I wouldn't have thought
of that.  But I'm not sure it helps my ultimate goal of
simplifying my application code or that it doesn't shift
the problem of not leaking savepoints to the test
savepoints.

В списке pgsql-general по дате отправления
От: Stuart McGraw
Дата:
Сообщение: Re: existence of a savepoint?
От: nageswara Bandla
Дата:
FAQ