Re: PL/pgSQL bug?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: PL/pgSQL bug?
Дата
Msg-id 16453.997709920@sss.pgh.pa.us
обсуждение исходный текст
Ответ на RE: PL/pgSQL bug?  ("Hiroshi Inoue" <Inoue@tpf.co.jp>)
Ответы Re: PL/pgSQL bug?
Список pgsql-hackers
"Hiroshi Inoue" <Inoue@tpf.co.jp> writes:
> It's possible for a function to use a unique snapshot
> if there are only SELECT statements in the function
> but it's impossible if there are UPDATE/DELETE or
> SELECT .. FOR UPDATE statements etc.

You are confusing snapshots (which determine visibility of the results
of OTHER transactions) with command-counter incrementing (which
determines visibility of the results of OUR OWN transaction).  I agree
that plpgsql's handling of command-counter changes is broken, but it
does not follow that sprinkling the code with SetQuerySnapshot is wise.
        regards, tom lane


В списке pgsql-hackers по дате отправления: