Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how to delete all duplicate records from a table using
subquery?

Answer Posted / lingareddy

by using below sub query delete duplicate all records:

DELETE FROM dept WHERE salary IN (
SELECT salary FROM dept GROUP BY salary HAVING ( COUNT(salary) > 1 ))


here is dept is the table name
salary is the column name

for any doubts about SQL contact with me

Thanks & Regards
Lingareddy.S

Is This Answer Correct ?    0 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a Garbage Collection? and what is full recursive Garbage collection?

2956


What is the relation of a user account and a schema in oracle?

1126


What is a cursor in oracle?

1228


What is program global area (pga) in oracle?

1090


Why does oracle 9i treat an empty string as null?

1129


What is oracle host variable?

1131


What is data block in Oracle?

1148


How we can able to import our own template (users designed MS-Word templates) which has many tabular columns; need to pass some values generate by Oracle-reports9i? Actually need to import more than 400 MS-Word templates into Oracle Reports-9i to minimize layout design in Reports.

2261


Why does for update in oracle 8 cause an ora-01002 error?

1046


What are temporal data types in oracle?

1167


What is the usage of merge statement?

1203


How to omit columns with default values in insert statement in oracle?

1099


How to commit the current transaction in oracle?

1180


What is bulk collect in oracle?

1053


Can I create users through internet explorer in oracle 10g?

1157