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

finding (and recycling) holes in sequences

From: Louis-David Mitterrand <cunctator(at)apartia(dot)ch>
To: pgsql-sql(at)postgresql(dot)org
Subject: finding (and recycling) holes in sequences
Date: 2000-06-25 07:52:45
Message-ID: 20000625095245.A8162@styx (view raw or flat)
Thread:
Lists: pgsql-sql
If one has a unique-id generating sequence that sometimes is bound to
have holes in it (ie: it could happen that a nextval(seq) happens
without a corresponding INSERT in the table), then how could one
efficiently scan for these holes to recycle them in subsequent INSERTs?

I'm just looking for a "standard" way of doing this if such a thing
exists.

TIA

-- 
Louis-David Mitterrand - ldm(at)apartia(dot)org - http://www.apartia.fr

"For a list of the ways which technology has failed to improve our
quality of life, press 3." 

pgsql-sql by date

Next:From: Oliver ElphickDate: 2000-06-25 23:05:58
Subject: JOIN syntax
Previous:From: Tom LaneDate: 2000-06-25 02:19:25
Subject: Re: More full text index..

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