Re: Need some help in postgres locking mechanism

Поиск
Список
Период
Сортировка
От santhosh kumar
Тема Re: Need some help in postgres locking mechanism
Дата
Msg-id CAOE+M7EGxMOjDAL6v2MmdjtfHFrcoAJopQX6Jpe3cDh5z2xT+Q@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Need some help in postgres locking mechanism  (Hannes Erven <hannes@erven.at>)
Список pgsql-general
Thanks alot..i have implemented in same format.You people are awesome.Thank You once again


On Tue, Apr 8, 2014 at 8:58 PM, Hannes Erven <hannes@erven.at> wrote:
Hi,


On 2014-04-08 15:27, Vick Khera wrote:
[...]

Problem 2: you cannot have a second process skip over locked rows.


In fact, you can: use "FOR UPDATE NOWAIT" and catch any errors.

e.g. SELECT * FROM jobqueue WHERE id=? FOR UPDATE NOWAIT



-hannes



--
K.Santhosh Kumar
Member of Technical Staff
Groupon,Chennai

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: is there a way to firmly cap postgres worker memory consumption?
Следующее
От: Sergey Konoplev
Дата:
Сообщение: Re: streaming replication and recovery