Insert Rows in between a SQL Server Table with Identity Column

SET IDENTITY_INSERT YourTableName ON

INSERT INTO
YourTableName(CustId, FirstName, LastName)
VALUES (18, 'Paul', 'Adams')
GO

SET IDENTITY_INSERT
YourTableName OFF

But we must use insert into table_name(columns) values(values)
Otherwise it willnot work

Comments

Popular posts from this blog

IBM FileNet: Bulk Processing using JavaScript

ASP.NET Web API Tutorial for Beginners

DB2 Date Time Functions