Click here to Skip to main content
15,902,922 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Example:
create table emp1(id int identity(1,1),name varchar(40))
insert int emp1 values('jhanu')
insert into emp1 values('vijji')
select * from emp1
Result:
id name
1 jhanu
2 vijji
Delete from emp1
Records will be deleted from table
Again i am inserting data in the table emp1
insert into emp1 values('Pravi')
it will show the out put
id name
3 pravi
But i need after delete the Rows from table i need to display identity field value start from 1 only
example
id name
1 pravi
like this i should display,
So anybody knows this type of query pls Help me I am very new to sqlserever
Posted

1 solution

 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900