Re: Increment a sequence by more than one

From: Michael Glaesemann <grzm(at)seespotcode(dot)net>
To: Erik Jones <erik(at)myemma(dot)com>
Cc: Steve Midgley <public(at)misuse(dot)org>, pgsql-sql(at)postgresql(dot)org
Subject: Re: Increment a sequence by more than one
Date: 2007-08-03 20:33:28
Message-ID: 6137A8C5-187D-46E8-B9C2-822D05C5DFC2@seespotcode.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql


On Aug 3, 2007, at 15:27 , Erik Jones wrote:

> Is there actually a requirement that the block of 5000 values not
> have gaps?

Good point.

> If not, why not make the versioned table's id column default to
> nextval from the same sequence?

Of course, the ids of the two tables could be interleaved in this
case. This might not be an issue, of course.

Michael Glaesemann
grzm seespotcode net

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Steve Midgley 2007-08-03 20:56:46 Race condition in resetting a sequence
Previous Message Michael Glaesemann 2007-08-03 20:31:04 Re: Increment a sequence by more than one