libpq: trying to detect record locks

Поиск
Список
Период
Сортировка
От Jim Dossey
Тема libpq: trying to detect record locks
Дата
Msg-id 3740C867.39D903C1@mercury.net
обсуждение исходный текст
Список pgsql-interfaces
I'm trying to convert an existing application to postgresql 6.5.  I'm
using 6.5 because we need the "FOR UPDATE" clause in the SELECT
statement.  This is an interactive application and files locks would not
be acceptable.

I would like to find a way to detect if PQexec() or PQsendQuery() on a
"SELECT ... FOR UPDATE" command are blocked because one or more if the
records we are trying to select are locked by other transactions.  I
don't want the users waiting on a SELECT when the records they want are
in use by another user, and we don't know when they will be freed.

Thanks for any and all help,
-- 
-----------------------------------------------------------------------   
Jim Dossey                                       mailto:jfd@mercury.net


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

Предыдущее
От: Jim Dossey
Дата:
Сообщение: libpq: checking for record locks
Следующее
От: Thomas Lockhart
Дата:
Сообщение: Re: [INTERFACES] Vacuum takes for ever