Received: from localhost.localdomain (postgresql.org [64.49.215.8]) by localhost (Postfix) with ESMTP id C0BAA47603A for ; Mon, 6 May 2002 14:49:04 -0400 (EDT) Received: from bast.unixathome.org (bast.unixathome.org [216.187.105.150]) by postgresql.org (Postfix) with ESMTP id EB562475BDA for ; Mon, 6 May 2002 14:25:24 -0400 (EDT) Received: from wocker (wocker.unixathome.org [192.168.0.99]) by bast.unixathome.org (Postfix) with ESMTP id DE7B63F43; Mon, 7 May 2001 10:27:38 -0400 (EDT) From: "Dan Langille" Organization: DVL Software Limited To: "Joel Burton" Date: Mon, 6 May 2002 14:25:21 -0400 MIME-Version: 1.0 Subject: Re: SERIAL Field Reply-To: dan@langille.org Cc: In-reply-to: References: <20010507124341.00EE03F43@bast.unixathome.org> X-mailer: Pegasus Mail for Windows (v4.01) Content-type: text/plain; charset=US-ASCII Content-transfer-encoding: 7BIT Content-description: Mail message body Message-Id: <20010507142738.DE7B63F43@bast.unixathome.org> X-Archive-Number: 200205/36 X-Sequence-Number: 4211 On 6 May 2002 at 12:43, Joel Burton wrote: > > -----Original Message----- > > From: Dan Langille [mailto:dan@langille.org] > > Sent: Monday, May 06, 2002 12:41 PM > > To: Joel Burton > > Cc: pgsql-admin@postgresql.org > > Subject: Re: [ADMIN] SERIAL Field > > > > > In any event, inserting then using currval() is the standard practice > > > around here, and it works great. Nothing fishy at all here, > > nothing to see, > > > move on. > > > > Why is that "less risk"? > > It's not; nextval() is just fine. I was half asleep and thinking, I think, > of another database when I wrote that. > > "You say nextval() + write, I say write + currval()..." So long as a given application does not mix the two approaches, everything should be fine. -- Dan Langille The FreeBSD Diary - http://freebsddiary.org/ - practical examples