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
Is there any difference between the primary key and unique key?
can any body tell me how to know the password of current user in sql server
New concepts of sql server 2005 use in your project.
Explain can you implement data mining in ssrs?
What is an indexed view?
How to change the system date and time from SQL Plus Terminal ?
What is open database communication (odbc)?
What is the guest user account in sql server? What login is it mapped to it? : sql server security
What are sp_configure commands and set commands?
What is inline table-value user-defined function?
Explain different backup plans?
What are four major operators that can be used to combine conditions on a where clause?
How many types of schemas are there?
What are basics of policy management?
how to control the amount of free space in your index pages? : Sql server database administration