Write a query to delete duplicate records in SQL SERVER
Answer Posted / anuj dhingra
DELETE
FROM MyTable
WHERE ID NOT IN
(
SELECT MAX(ID)
FROM MyTable
GROUP BY DuplicateColumn1, DuplicateColumn2,
DuplicateColumn2)
| Is This Answer Correct ? | 12 Yes | 8 No |
Post New Answer View All Answers
Can sql servers link to other servers like oracle?
What are the source of constraints?
Can we shrink data file in sql server?
what is the difference between openrowset and openquery?
Why and when do stored procedure recompile?
What is the primary use of the model database?
what is the Ticketing tool used in Wipro technologies at Bangalore...???
Where can you add custom error messages to sql server?
What are wait types?
What is normalization and what are the advantages of it?
How to connect php with different port numbers?
How can you append an identity column to a temporary table?
What is self contained sub query?
what is spatial nonclustered index
Explain system functions or built-in functions? What are different types of system functions?