Re: How to speed up Exclusive Locking

Поиск
Список
Период
Сортировка
Искать
От
Bernd Helmle
Тема
Re: How to speed up Exclusive Locking
Дата
Msg-id
378dea27826636cae6e28ff7ef9cce80@oopsware.de
Ответ на
Список
Дерево обсуждения
How to speed up Exclusive Locking David Goodenough <david.goodenough@btconnect.com>
Re: How to speed up Exclusive Locking Bernd Helmle <mailings@oopsware.de>
Re: How to speed up Exclusive Locking David Goodenough <david.goodenough@btconnect.com>
Re: How to speed up Exclusive Locking Richard Huxton <dev@archonet.com>
Re: How to speed up Exclusive Locking David Goodenough <david.goodenough@btconnect.com>
Re: How to speed up Exclusive Locking Tom Lane <tgl@sss.pgh.pa.us>



On Tue, 5 Dec 2006 10:18:21 +0000, David Goodenough  wrote:

[...]

> The first bits of the sync are done without locking the source tables, and
> I do these until I find less than some suitable threshold of records
> needing
> to be updated.  Then I lock the source tables and do the final sync.
> 
> The statements issued to lock each table is:-
>  LOCK TABLE table IN EXCLUSIVE MODE; SELECT 1 FROM table;
> 

So why selecting '1' for each row after locking the relation before? I don't 
know HA-JDBC but this looks really useless. Remove the SELECT and use 
the LOCK TABLE command within the transaction which does the sync for you.

Bernd
В списке pgsql-general по дате отправления
От: Arnaud Lesauvage
Дата:
От: Faqeer ALI
Дата:
Сообщение: iplike.so access denied help!!
FAQ