September 20, 2007 at 12:41 am
There are two options here.
select distinct field1, field2
from table
or
select field1, field2
from table
group by field1, field2
Option 1 is the better for performance if you have a large table
September 20, 2007 at 12:46 am
That is fine
But I want to get the duplicate records deleted from my table
and get the final result
how is this possible in sql 2000
Thanks
September 20, 2007 at 12:54 am
select distinct name,salary
into #temptab
from tablename
truncate table tablename
insert into tablename
select name,salary from #temptab
regards
September 20, 2007 at 1:01 am
Thanks Sanjay.
It is working fine
Viewing 4 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply