Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: SEQUENCE/TRIGGER Problem
Chris Capson wrote:
>
> I am using a sequence In conjunction with a trigger to create an autonumber
> field everything seems be working fine except for every once and a while
> when I insert a record the sequence seems to jump over numbers in the
> sequence.
>
> Example:
>
> The sequence creates 1,2,3,4,5,10,11,12,21.
>
> Does anybody know what Might be causing this??
>
> Thanks
> Chris Capson
The DBMS preallocates sequence values for faster access. The allocation is related to a session. Usually the system preallocates more than one value. If the session finished the allocated values are lost. If you create a sequence you can define how many values the system will preallocate. Use CREATE SEQUENCE ... CACHE number ... to define the cache size.
Regards
Dennis
Received on Fri Feb 05 1999 - 05:34:35 CST