I have a T-SQL database in which there is table that suddenly got a huge jump in primary keys 5 -> 1005. Is there any way to reset PK back to eg. 6?
I have tried following:
USE [database name]
GO
ALTER SEQUENCE [schema name].[table name].[pk name]
RESTART WITH 6
GO
But it returns error 'CREATE SEQUENCE' does not allow specifying the database name as a prefix to the object name.
I have tried supposedly all the sensible variations of the query but without luck. Is there any other way to restart or reset the PK?