how to delete duplicate rows from a specified table(only
single table)
how do you know which join is need to be used
Answer Posted / arif jameel
First add an Identity Column in table
Alter table <tblname>
Add < New_columnID > int identity(1,1)
Delete from <tblname> where < New_columnID> in
(select max(New_columnID)from <tblname>
Group by <tbl_columnname>
having count (<tbl_columnname>)>1)
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
What are the uses of sysdate and user keywords?
What are the different types of dbmss?
In a distributed database system, can we execute two queries simultaneously?
Explain the uses of database trigger.
What is the difference between union and union all command?
What is minus?
What does a pl/sql package consist of?
Is id a reserved word in sql?
how to shutdown mysql server? : Sql dba
Is a secondary key the same as a foreign key?
What is a loop in sql?
How to avoid using cursors?
what are all the different normalizations? : Sql dba
What is a database trigger?
how many columns can be used for creating index? : Sql dba