Re: Unique sequence generator with reclaim

From: M. Armaghan Saqib <armaghan_at_yahoo.com>
Date: Sat, 18 Dec 1999 00:25:29 GMT
Message-ID: <83ek9k$jlr$1_at_nnrp1.deja.com>



Hi, Rami Zaatari

My SQLPlusPlus (freeware) generates pl/sql code using BLDAPI(tablename) which includes comments (and commented PL/SQL) which describe how to use a table based sequence number. All you need to use this is remove the comments and insert your column name for ID.

This code can also be modified very easily to accomodate your other requirements (renumber, reuse etc.)

Give it a try. If you have any difficulty implementing your requirement, I shall be happy to help you.

regards,
M. Armaghan Saqib


  • SQL PlusPlus : Add power to SQL Plus command line
  • SQL Link for XL : Integrate Oracle with XL
  • Oracle CBT with sample GL (Triggers and Forms Source Code included. Download free: http://www.geocities.com/armaghan/

Rami Zaatari <rzaatari_at_americasm01.nt.com> wrote in message news:385AC8C6.D2DB81D8_at_americasm01.nt.com...
> Hello,
>
> I have this issue that I believe somebdy else might have dealt with.
> Please take a look
>
> We need to have a unique ID sequence number generator for a certain
> table, but the one Oracle provides (SEQNAME.NEXTVAL) will not work
well
> for us, for the following reasons:
>
> 1. we need to be able to reclaim back lost sequence numbers/ ids (in
> case records with ids were deleted)
> 2. we need to let the user skips and enters a unique sequence
number/id,
> and the sequence generator should take care of it in case it reached
> that id later.
>
> I appreciate any hints/lead/thoughts about that. Does Oracle provide a
> more intelligent sequence.
>
> Thank you for your attention,
>
> Rami
>
> -------------------------------------------------------------
> Rami M. Zaatari N O R T E L N E T W O R K S
> rzaatari_at_nortelnetworks.com Carrier Packet Solutions
> (919) 905-3534/ESN 355-3534 NCRTP, Dept. B932
> (919) 991-4088 (Fax) RTP, NC 27709
>

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Sat Dec 18 1999 - 01:25:29 CET

Original text of this message