Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

identity insert on sql server

SET IDENTITY_INSERT sometableWithIdentity ON

INSERT sometableWithIdentity (IdentityColumn, col2, col3, ...)
VALUES (AnIdentityValue, col2value, col3value, ...)

SET IDENTITY_INSERT sometableWithIdentity OFF
 
PREVIOUS NEXT
Tagged: #identity #insert #sql #server
ADD COMMENT
Topic
Name
1+1 =