Re: Rows with exclusive lock

From: Florian Weimer <fw(at)deneb(dot)enyo(dot)de>
To: Martin Marques <martin(at)bugs(dot)unl(dot)edu(dot)ar>
Cc: Alvaro Herrera <alvherre(at)commandprompt(dot)com>, pgsql-sql(at)postgresql(dot)org
Subject: Re: Rows with exclusive lock
Date: 2006-07-23 15:28:28
Message-ID: 87fygss5lv.fsf@mid.deneb.enyo.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

* Martin Marques:

>> That's what SELECT FOR UPDATE does.
>
> Hi Alvaro,
>
> After the SELECT FOR UPDATE other transactions can still see the
> locked rows. I want a read/write lock, so no one can access does rows.

You should probably run the other transactions at SERIALIZABLE level.
I suppose this will make them wait for the completion of the update.

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Alvaro Herrera 2006-07-23 16:10:51 Re: Rows with exclusive lock
Previous Message Martin Marques 2006-07-22 14:55:38 Re: Rows with exclusive lock