How to delete duplicate records from a table?(for suppose in
a table we have 1000 Records in that we have 200 duplicate
Records , so ,how to findout that duplicate Records , how to
delete those Records and arranged into sequence order? one
more thing that there is no primary key at all)

Answer Posted / sirisha

with numbered as(select rowno = row_number() over(partition
by empid order by empid),empname from employee)delete from
numbered where rowno > 1

Is This Answer Correct ?    1 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are two difference between sql azure and azure tables?

137


Can sql server be linked with other servers like oracle?

519


What is explicit mode in sql server?

529


Tell me the difference between clustered and non-clustered index?

506


What is the difference between join and inner join?

534






How to configure and test odbc dsn settings?

567


Which is better statement or preparedstatement?

518


What happens if you are trying to access a schema not owned by you?

506


How do you delete a data source?

535


What is dknf in normalization form?

553


Do you know what is difference between stored procedure and user defined function?

608


Which sql server table is used to hold the stored procedure script?

473


what is the maximum size of a row? : Sql server database administration

531


Why we should not use triggers?

534


How to select all columns of all rows from a table with a select statement in ms sql server?

570