how to delete duplicate rows from table in sql server
Answer Posted / vineet dhamija
the best approach i came across in simple form too
just create a temporary table with the distinct values and
truncate this table than copy the values back and u r good to go
select distinct * into #temp from urtable
truncate table urtable
insert into urtable select * from #temp
drop table #temp
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why do we use sql limitations? Which constraints can we use while making a database in sql?
What is a mutating table error and how can you get around it?
Explain can SSRS reports Cache results?
What is use of attribute hierarchy optimized state? : sql server analysis services, ssas
How to use wildcard characters in like operations in ms sql server?
What is the native system stored procedure to execute a command against all databases?
When should you use an instead of trigger?
How many columns can exist together per table?
How to maintain a fill factor in existing indexes?
List out the differences between global and local temp tables in sql server?
Explain the various types of concurrency problem?
What is the rdl file?
What is the size of transaction log file?
Why do you need a sql server?
Explain how you can deploy an SSRS report?