| От | Michael Fuhr |
|---|---|
| Тема | Re: update table with row locking |
| Дата | |
| Msg-id | 20041223203303.GA68180@winnie.fuhr.org обсуждение исходный текст |
| Ответ на | update table with row locking (Mark <sendmailtomark@yahoo.com>) |
| Ответы |
Re: update table with row locking
|
| Список | pgsql-general |
On Thu, Dec 23, 2004 at 11:56:26AM -0800, Mark wrote: > Is it possible to lock row(s) when updating a table, so another call > for update( from different session) will be rejected and to be on > hold until lock get released ? The UPDATE statement automatically acquires locks, but if you need more control then you could use SELECT FOR UPDATE or LOCK. For more information see the "Concurrency Control" chapter in the documentation. What problem are you trying to solve? Depending on what you're doing, you might not need to use explicit locking. -- Michael Fuhr http://www.fuhr.org/~mfuhr/
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера