Say if we have a table that contains only a single column ,
say OrderID, which has IDENTITY attribute defined on it. So
how can we insert data in this table.
I am reframing my question, that how can we make the table
to increment the column "OrderID" value several times???
Answer Posted / madhu
To insert values into Identity column use the
IDENTITY_INSERT option like
SET IDENTITY_INSERT Table_Name ON
Insert Table_Name
(OrderID)
Values(10)
SET IDENTITY_INSERT Table_Name OFF
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
Why the trigger fires multiple times in single login?
Are all views updatable ?
What is clustered primary key?
Beginning with sql server version 7 0, a new enhanced data type nchar was added what type of data is supported with this data type?
What is the difference between left and right outer join?
Explain what is lock escalation?
How can I change procedure name in sql server?
what is the primary use of the model database? : Sql server administration
What is policy management?
What is a periodical index?
What does this statement do @@rowcount?
What are the filtered indexes?
What is cached report?
What is explicit cursors?
how to create a scrollable cursor with the scroll option? : Sql server database administration