write a query to remove duplicate records without using primary key column?
Answers were Sorted based on User's Feedback
Answer / mathanrathinam
delete tmp from(select col1,col2,row_number over(partition by col1,col2 order by col1,col2) rownum from tablename) tmp
where rownum >1
| Is This Answer Correct ? | 7 Yes | 8 No |
What is difference between drop truncate and delete?
How to use clusters?
Explain indexed view?
What language is sql server written in?
What are scheduled tasks in sql server?
How to handle error or exception in sql?
What are the operating modes in which database mirroring runs?
can you any body tell me why are go for the rebuild the master database.what is the reason?
What is query optimization process?
can any one post me, how to remove rows in the below table ENO ENAME EDEPT ELOC 3368 BPS BI Adayar 3371 RAN BI valachari 3369 SRI BI valachari 3372 jay BI Chn - - - - - - - -
What is cursors? And what are the different types of cursor?
What are user-defined functions (udfs) in sql server?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)