Received: from erm1.u-strasbg.fr (erm1.u-strasbg.fr [130.79.74.61]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f5KEcMa30684 for ; Wed, 20 Jun 2001 10:38:23 -0400 (EDT) (envelope-from bboett@erm1.u-strasbg.fr) Received: by erm1.u-strasbg.fr (Postfix, from userid 501) id CFB0D5E37; Wed, 20 Jun 2001 16:46:36 +0200 (CEST) Date: Wed, 20 Jun 2001 16:46:36 +0200 To: pgsql-sql@postgresql.org Subject: possible to lock a single row in table? Message-ID: <20010620164636.J13678@erm1.u-strasbg.fr> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline User-Agent: Mutt/1.3.15i From: bboett@erm1.u-strasbg.fr (Bruno Boettcher) X-Archive-Number: 200106/302 X-Sequence-Number: 3565 Hello! i have a lots of threads that work on a table, making insertions, updates removes..... now i certain cases its important to keep data integrity, so i looked into locks.... all i found was a lock function that locks the entire table.... now even in shared mode, if i understand it well this means that as long as the locking procedure isn't finished, no other thread can update or delete data, right? Thats really harsh, since there are really an awful lot of threads.... isn't it possible to lock only a specific row? and what happens to other insert queries whilst the lock is operational? Are they postponed and the valling thread waits, or does the call return with an error? -- ciao bboett ============================================================== bboett@earthling.net http://inforezo.u-strasbg.fr/~bboett http://erm1.u-strasbg.fr/~bboett =============================================================== the total amount of intelligence on earth is constant. human population is growing....