X-Original-To: pgsql-sql-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id BC9DF9FAC76 for ; Fri, 7 Jul 2006 10:14:27 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 19361-05 for ; Fri, 7 Jul 2006 10:14:27 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from grzm.com (grzm.com [200.46.204.98]) by postgresql.org (Postfix) with ESMTP id 7FCCD9F97C2 for ; Fri, 7 Jul 2006 10:14:27 -0300 (ADT) Received: from localhost (unknown [200.46.208.251]) by grzm.com (Postfix) with ESMTP id E15A3127D37F for ; Fri, 7 Jul 2006 14:14:21 +0100 (BST) Received: from grzm.com ([200.46.204.98]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 05254-04; Fri, 7 Jul 2006 10:14:18 -0300 (ADT) Received: from [141.117.21.211] (s21-211.resnet.ryerson.ca [141.117.21.211]) by grzm.com (Postfix) with ESMTP id E28B2127C4ED; Fri, 7 Jul 2006 14:14:12 +0100 (BST) In-Reply-To: References: Mime-Version: 1.0 (Apple Message framework v752.2) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <279E27B5-183F-4520-BC43-A726A50646EF@seespotcode.net> Cc: Content-Transfer-Encoding: 7bit From: Michael Glaesemann Subject: Re: Atomar SQL Statement Date: Fri, 7 Jul 2006 09:14:16 -0400 To: "Weber, Johann (ISS Kassel)" X-Mailer: Apple Mail (2.752.2) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200607/96 X-Sequence-Number: 25670 On Jul 7, 2006, at 7:55 , Weber, Johann (ISS Kassel) wrote: > My concern: in a multi threaded environment, can a second thread > interrupt this statement and eventually insert the same email > address in > the table with a different id? Or is this statement atomar? You're safe. Take a look at the FAQ entries on SERIAL: http://www.postgresql.org/docs/faqs.FAQ.html#item4.11.2 Hope this helps. Michael Glaesemann grzm seespotcode net