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 is a temp table?
What is graph sql?
Can a table contain multiple primary key’s?
how does a local variable is defined using t-sql? : Transact sql
how to rename an existing table in mysql? : Sql dba
How many aggregate functions are available there in sql?
Can a table contain multiple foreign key’s?
What is $$ in sql?
How can check sql version from command line?
Which is better trigger or stored procedure?
What are pl sql data types?
Which data dictionary views have the information on the triggers that are available in the database?
Does postgresql run on the cloud?
What is the difference between the sql*loader and import utilities? : aql loader
What is the use of partition by in sql?