>>Hi,
>>
>>I have a customer that reported that a primary key field (Identity column) increased by about 1000. That is it was 80 and then became 1002. The user can see the PK field value. I check the database and see that nothing has been changed for this table/column. But it clearly changed. As if someone - from the SQL Server end - created a bunch of records and then deleted them.
>>Any idea how this would happen?
>
>Newer versions aim for higher throughput and keep Identity managment in memory to speed up inserts. As long as server is not restarted, no gaps should appear, but on restarts gap is possible. I am pretty certain that there is a flag that can force SQL server to the previous behaviour. In most cases gaps should NOT matter - I am a believer in surrogate keys.
>
>//upd: I hate it when memory is somewhat fuzzy... so I googled to sharpen
>
https://stackoverflow.com/questions/17587094/identity-column-value-suddenly-jumps-to-1001-in-sql-server>
>not too far off ;-)
Thank you for the link.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham