Re: currval() race condition on server?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: currval() race condition on server?
Дата
Msg-id 23634.1161613423@sss.pgh.pa.us
обсуждение исходный текст
Ответ на currval() race condition on server?  (Adriaan Joubert <a.joubert@albourne.com>)
Ответы Re: currval() race condition on server?
Список pgsql-jdbc
Adriaan Joubert <a.joubert@albourne.com> writes:
> For some bookkeeping purposes I need the new audit number back from the
> update, so I submit a prepared statement through jdbc of the form
>
> UPDATE A SET ....; SELECT currval('ip_audit_seq');

It's not possible to put two SQL commands into one prepared statement
--- at least not for the normal server-side meaning of "prepared statement".
I dunno what the JDBC driver is doing with this, but I wonder if it's
silently dropping the UPDATE part :-(

            regards, tom lane

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

Предыдущее
От: Achilleas Mantzios
Дата:
Сообщение: Re: currval() race condition on server?
Следующее
От: Dave Cramer
Дата:
Сообщение: Re: currval() race condition on server?