here id col have primary key and identity
id name
1 a
2 b
3 c
4 d
delete 2nd row then o/p will be
id name
1 a
3 c
4 d
next inssert 2nd row and i want o/p will be
id name
1 a
2 e
3 c
4 d
Answer Posted / sunilkumar
set identity_insert on
insert into test1(Id ,id_name) values (2 ,'insertedat2')
Is This Answer Correct ? | 7 Yes | 3 No |
Post New Answer View All Answers
How do I find the port number for sql server?
Can we use trigger new in before insert?
What are the drawbacks of reporting in ssrs?
What are SSL and TSL protocols?
What are the properties of sub-query?
What objects does the fn_my_permissions function reports on? : sql server security
What are the differences between left join and inner join in sql server?
Distinguish between commit and rollback?
What are the limitations in ssrs on sql server express edition?
How do clustered indexes store data?
how can you check the level of fragmentation on a table? : Sql server administration
What is deploy, process and build? : sql server analysis services, ssas
What is the difference between a primary key and a unique key? Are they the same?
what are the reporting service components in SSRS?
How to send a ssrs report from ssis?