write sub query for eliminating duplicate rows using
analytical function?

Answer Posted / korimantu

delete from table name where rowid not in(select max(rowid)
from group by last_name);

or

delete from table name where rowid>(select min(rowid) from
where a.last_name=b.last_name);

Is This Answer Correct ?    4 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is sql harder than python?

811


Can we join 3 tables in sql?

697


What is delimiter sql?

698


How to create a menu in sqlplus or pl/sql?

799


how can you see all indexes defined for a table? : Sql dba

702






Which is faster truncate or drop?

769


explain mysql aggregate functions. : Sql dba

717


How do I count records in sql?

723


What pl/sql package consists of?

831


What does data normalization mean?

712


Which nosql database is best?

672


What is the difference between a query and a report?

674


What is normalization? How many normalization forms are there?

741


How is data stored in sql?

718


What are the built in functions of sql?

750