pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Dave Cramer <pg@fastcrypt.com>
To: bitrunner <bitrunner@katamail.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: help lock record
Date: Tue, 23 May 2006 14:40:18 -0400
Message-ID: <3BAF0B35-0961-4581-AE90-CC14598D856A@fastcrypt.com> (raw)
In-Reply-To: <4473483E.9090202@katamail.com>
References: <4473483E.9090202@katamail.com>


On 23-May-06, at 1:37 PM, bitrunner wrote:

> For lock the record I use:
> select * from orders where id = 17 for update
>
> in this way lock the record with id = 17.
> If an other user demands the same record as I can understand that  
> it is lock?
yes as long as autocommit is false this is true. In other words as  
long as you do this inside a transaction/
>
> Thanks a lot.
>
> ---------------------------(end of  
> broadcast)---------------------------
> TIP 2: Don't 'kill -9' the postmaster
>




view thread (4+ messages)  latest in thread

Message-ID: <3BAF0B35-0961-4581-AE90-CC14598D856A@fastcrypt.com>
Permalink:  ../3BAF0B35-0961-4581-AE90-CC14598D856A@fastcrypt.com/
Also on:    postgresql.org/message-id/3BAF0B35-0961-4581-AE90-CC14598D856A@fastcrypt.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: pg@fastcrypt.com, bitrunner@katamail.com
  Subject: Re: help lock record
  In-Reply-To: <3BAF0B35-0961-4581-AE90-CC14598D856A@fastcrypt.com>
  References: <4473483E.9090202@katamail.com> <3BAF0B35-0961-4581-AE90-CC14598D856A@fastcrypt.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox