Identity Column jumps massively from 168712 to 9999993

Perumal, Gowthami 5 Reputation points
2025-10-17T16:06:46.38+00:00

I have table with identity column id. There was massive jump from id 168712 to 9999993. It has happened twice in different servers. Its not identity cache/transaction rollback/manual insert/ reseed. Why its happening. Please guide me on this.

SQL Server | SQL Server Transact-SQL
{count} votes

1 answer

Sort by: Most helpful
  1. Erland Sommarskog 128.6K Reputation points MVP Volunteer Moderator
    2025-10-18T16:45:53.7333333+00:00

    Why would you care? I mean, if you cared, why did you pick a column property that means "I don't care"?

    But apart from that, it is a little unexpected in so far that it does not seem to be due to the identity cache, since the cache is 1000 for int and 10000 for bigint.

    But it could be due to DBCC CHECKIDENT or inserts with SET IDENITITY_INSERT ON. You seem to rule out these, but it is not clear to me why you can be such sure.

    But may be most likely reason is a failed multi-row insert. If you attempt to insert 10 million rows, and this fails for some reason, you may consume 10 million IDENTITY values.

    1 person found this answer helpful.

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.