Re: It looks like transaction, but it isn't transaction

Поиск
Список
Период
Сортировка
Искать
От
Sam Mason
Тема
Re: It looks like transaction, but it isn't transaction
Дата
Msg-id
20090826182303.GS5407@samason.me.uk
Ответ на
Список
Дерево обсуждения
It looks like transaction, but it isn't transaction Sergey Samokhin <prikrutil@gmail.com>
Re: It looks like transaction, but it isn't transaction Sam Mason <sam@samason.me.uk>
Re: It looks like transaction, but it isn't transaction Sergey Samokhin <prikrutil@gmail.com>
Re: It looks like transaction, but it isn't transaction Tom Lane <tgl@sss.pgh.pa.us>
Re: It looks like transaction, but it isn't transaction Sergey Samokhin <prikrutil@gmail.com>
On Wed, Aug 26, 2009 at 05:06:27AM +0400, Sergey Samokhin wrote:
> There is one thing I find especially interesting: queries I pass to
> the pgsql:squery() are executed with some properties specific to
> transactions!

This behavior seems to be what libpq exposes by default:

  http://www.postgresql.org/docs/current/static/libpq-exec.html

Not sure if it's actually PG imposing these semantics or the libpq driver
itself.  I'd guess it's PG and that's why you're seeing the strange lack
of support for savepoints.

> I'm going to rely on this behaviour as "transactions without
> SAVEPOINT/ROLLBACK TO" in some cases but I'm a bit afraid of troubles
> that may appear in the future.

I always tend to bracket things in an explicit BEGIN+COMMIT, why
wouldn't you do this?

-- 
  Sam  http://samason.me.uk/
В списке pgsql-general по дате отправления
От: Thomas Kellerer
Дата:
От: Magnus Hagander
Дата:
FAQ