Skip site navigation (1) Skip section navigation (2)

Re: next value expression

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Neil Conway <neilc(at)samurai(dot)com>
Cc: Manfred Koizar <mkoi-pg(at)aon(dot)at>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: next value expression
Date: 2002-11-27 17:24:14
Message-ID: 18666.1038417854@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackers
Neil Conway <neilc(at)samurai(dot)com> writes:
> On Wed, 2002-11-27 at 10:29, Manfred Koizar wrote:
>> By accident I stumbled across the following paragraph in the August
>> 2002 draft of SQL 2003:
>> 
>> If there are multiple instances of <next value expression>s
>> specifying the same sequence generator within a single
>> SQL-statement, all those instances return the same value for a
>> given row processed by that SQL-statement.
>> 
>> Is this of any relevance to PG's nextval()?

> Somewhat -- SQL2003 defines sequence generators that are pretty much
> identical in functionality to PostgreSQL's sequences, although the
> syntax is a bit different.

I would think his point is that the above paragraph specifies behavior
that is very definitely NOT like Postgres'.

> I submitted a patch for 7.4 that adjusts the
> CREATE SEQUENCE grammar to match SQL2003's CREATE SEQUENCE a little more
> closely,

Did we apply it?  I'm inclined not to, until we nail down the semantic
implications a little more.  Conforming to the spec on syntax when we
don't on semantics strikes me as a bad idea.

			regards, tom lane

In response to

Responses

pgsql-hackers by date

Next:From: Neil ConwayDate: 2002-11-27 18:20:19
Subject: Re: next value expression
Previous:From: Thomas A. LoweryDate: 2002-11-27 17:20:00
Subject: Re: Interface update for 7.3

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group