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
Explain about thread and memory management process of SQL?
can you implement data mining in SSRS?
How to edit table in sql server 2017?
What is partition, how will you implement it? : sql server analysis services, ssas
A user is a member of the public role and the sales role. The public role has select permission on all the tables. The sales role does not have select permission on some of the tables will the user be able to select from all tables?
How to enable/disable indexes?
Explain sql delete command?
What is surrogate key? : sql server analysis services, ssas
What is the Disadvantage of indexed sequential file.
Difference Between ORDER BY Clause and GROUP BY Clause in SQL?
What are out-of-range errors with date and time literals?
Where are SQL server users names and passwords are stored in sql server?
What is transaction server consistency?
What is a select query statement in ms sql server?
What are various limitations of the views?