Re: [araman@india-today.com: locking problem with JDBC (suspicion)]

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [araman@india-today.com: locking problem with JDBC (suspicion)]
Дата
Msg-id 4522.982076877@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [araman@india-today.com: locking problem with JDBC (suspicion)]  ("Richard Huxton" <dev@archonet.com>)
Ответы Re: [araman@india-today.com: locking problem with JDBC (suspicion)]  (Anand Raman <araman@india-today.com>)
Список pgsql-general
"Richard Huxton" <dev@archonet.com> writes:
> Well, foreign keys enforce constraints so it's not unreasonable that the
> lock might extend to the referenced tables.

Precisely.  The SELECT FOR UPDATE is done to ensure that the referenced
rows don't go away before the update of the referencing table commits.

I'm guessing that Anand's not shown us all the operations involved,
and that when things hang up it's because there are two different
transactions trying to lock overlapping sets of referenced rows.
Hard to tell from the info we have, however.

            regards, tom lane

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: "downgrade" 7.1.x to 7.0.x
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: Re: numeric type and odbc from access 2000