This is somewhat related to question: SQL server identity column values start at 0 instead of 1
But I'm not sure what happening here. We have our "blank" database which we use to start customer's accounts. We do that by backing up and restoring database.
Customer gets completely blank tables after restore. Example of table, all our tables have PKs exactly like this one:
CREATE TABLE [dbo].[RNPRatePlanStop]
(
[RatePlanStopKey] [int] IDENTITY(1,1) NOT NULL,
[RatePlanKey] [int] NOT NULL,
.....
)
Once in a while (not always and not on all tables) when new record inserted - 0
not expected 1
inserted. I'm not sure how this can be fixed or what I'm doing wrong. This is causing problems in UI because we don't count on having 0
keys..