Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Sequence NextVal jumping 18 on reboot!
As two other posters have noted, the sequence value stored on disc is incremented by the sequence's 'cache size'. If you crash the database (by rebooting the PC without a proper Oracle shutdown), the values between the current value and the value stored on disc are lost.
If you shut the database down cleanly before rebooting then the current value is written back to disc before shutdown, and your values will not go missing.
(At least, that's how it used to work, but I haven't checked it for several years).
Jonathan Lewis
Yet another Oracle-related web site: www.jlcomp.demon.co.uk
Adrian Harrison wrote in message <369f1c53.196021_at_news.globalnet.co.uk>...
>Using NT4 Server, Personal Oracle 7.3.4
>
>Please someone tell me I'm not going stupid but every time I reboot my PC
the NEXTVAL in a very
>simply sequence (see below) increases by 18!
>
>For example if the last CRAFT_ID used was 3 on reboot the new one's 21
>
>Here is the code - generated by Oracle Migration Wizard for MS Access!
>
>///////////////////////////////////////////////////////////////////////////
/////////////////
/////////////////