One. Turn off automatic identity column auto-growth:
The command required for the operation is: SET Identity_insert [table][on| OFF] After the parameter is "on", means: Open the Identity column manual insertion function. Once the command execution succeeds to insert data into the table thereafter, the automatic identity column will not grow automatically, and the contents of this column need to be inserted manually. Of course, after the data addition operation is completed, we need to turn on the "autogrow" function again, that is, the above statement is executed again, but the last parameter is replaced with "OFF", which means "Exit Identity manual Insertion function".
Two. Reset the value of the identity column to a value:
The commands required for the operation are: DBCC checkident (table,[reseed| NORESEED],[1]) Three parameters are required in parentheses, the first is the name of the table in which the identity column resides, the second is an optional two parameter, the type of operation (select "Reseed" is represented as "reset operation", and a third parameter is required to provide the value to be reset.) If you select Noreseed as the view operation, you do not need a third parameter at this point, and the third is the seed value of the identity column to reset to.
The primary key in the SQL Server database automatically grows some special actions for the identity column