Disable identity insert in SQL Server

SET IDENTITY_INSERT dbo.table_name OFF
INSERT INTO table_name( [Id] , [Name])
SELECT 1 , 'Name1'
SET IDENTITY_INSERT dbo.table_name ON
GO

Comments

  1. Very Good information, the information which you have provided is very good and necessary for everyone. Always keep sharing this kind of information. Thank you. IT support Miami

    ReplyDelete

Post a Comment

Popular posts from this blog

Tibco Rendezvous (tibrv) C# .Net example

Parse XML to dynamic object in C#