Wednesday 8 June 2016

An explicit value for the identity column in table 'user' can only be specified when a column list is used and IDENTITY_INSERT is ON

Msg 8101, Level 16, State 1, Line 1
An explicit value for the identity column in table 'user' can only be specified when a column list is used and IDENTITY_INSERT is ON.

This is because userId column in user table is primary and identity key.
So you should be used IDENTITY_INSERT is ON or Please leave that column as it is.
Means don't insert that column value, it will automatically generate value.

No comments:

Post a Comment