Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Question on sequence number with Dual Table
Hi John,
Is the sequence defined with a cache like the following example ?
CREATE SEQUENCE abc INCREMENT BY 1
START WITH 1 MINVALUE 1
MAXVALUE 999999999
NOCYCLE NOORDER CACHE 20 (or maybe 8 in your case)
If yes, then this can be the answer.
Otherwise, some INSERTs (with the numbers 4-10) may fail, then used sequence
numbers are "lost".
Rgds
Dirk
"John Yang" <zyang_at_waveline.com> schrieb im Newsbeitrag
news:c137b465.0211200434.5a1c2b9e_at_posting.google.com...
> I am a beginner here, so I would really appreciate if you could give
> me some pointers to the following problem.
>
> I am using the Dual table to generate increasing sequence numbers,
> 1,2,3.... But the output numbers seems to jump from time to time, i.e.
> 1,2,3,11,12...
>
> First of all, I don't know if this is the best way of generating
> incremental sequence numbers. Second, I could not understand why the
> sequence number jumps, since there is only one instance calling the
> Dual table, why should it not be sequential? Or is it supposed to be
> sequential?
> I am running on Linux.
>
> Many thanks in advance.
>
> John
Received on Wed Nov 20 2002 - 06:43:36 CST
![]() |
![]() |