support for NEXT VALUE FOR expression - Mailing list pgsql-hackers

From Peter Eisentraut
Subject support for NEXT VALUE FOR expression
Date
Msg-id 222bdd8b-7702-64e9-82f3-14ce2ca43875@2ndquadrant.com
Whole thread Raw
Responses Re: support for NEXT VALUE FOR expression  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: support for NEXT VALUE FOR expression  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Here is a patch for implementing the NEXT VALUE FOR expression.  This is
the SQL-standard conforming version of our nextval() function, and it's
also used by Oracle, MS SQL, DB2.  Example:

SELECT NEXT VALUE FOR foo_seq;

The second patch changes the serial column to use this new expression
for its generated default values.  This doesn't make an external
difference except perhaps that the generated expression looks less weird
to the user.

--
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Attachment

pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: LWLocks in DSM memory
Next
From: Tom Lane
Date:
Subject: Re: support for NEXT VALUE FOR expression