Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 4E3B74759BD for ; Thu, 29 Aug 2002 20:53:37 -0400 (EDT) Received: from vote-smart.org (unknown [12.32.42.180]) by postgresql.org (Postfix) with SMTP id DBCB6475CF8 for ; Thu, 29 Aug 2002 20:53:35 -0400 (EDT) Received: (qmail 10044 invoked by uid 1041); 30 Aug 2002 00:57:36 -0000 Received: from clinton@vote-smart.org by eleanor2 by uid 1038 with qmail-scanner-1.10 (hbedv: 6.12.0.0. . Clear:0. Processed in 0.45671 secs); 30 Aug 2002 00:57:36 -0000 Received: from dhcp-216.vote-smart.org (HELO berry.vote-smart.org) (192.168.255.216) by eleanor2.vote-smart.org with SMTP; 30 Aug 2002 00:57:35 -0000 Content-Type: text/plain; charset="iso-8859-1" From: Clinton Adams Reply-To: clinton@vote-smart.org To: Bruno Wolff III Subject: Re: How do I get the rec-id from an insert. Date: Thu, 29 Aug 2002 18:52:46 -0600 User-Agent: KMail/1.4.3 Cc: pgsql-php@postgresql.org References: <200208272340.17513.chris@cdrbill.com> <200208291500.15392.clinton@vote-smart.org> <20020829225815.GB347@wolff.to> In-Reply-To: <20020829225815.GB347@wolff.to> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-Id: <200208291852.46769.clinton@vote-smart.org> X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200208/109 X-Sequence-Number: 1454 Bruno - Three sequences are involved in the INSERT. If one sequence were involved, then the expressions would be evaluated left to right, at least from what I can tell through my tests. Not something I would ever use...or rely on, for that matter. On Thu August 29 2002 16:58, Bruno Wolff III graced us with the following - > > insert into c values (nextval('crecid'), currval('arecid'), > > currval('brecid')) > > Is it documented that the above is reliable? I don't remember ever reading > that expressions are evaluated in the order they appear in a select > statement.