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 / aseem k

Tried and tested:
Table d:
7
8
7

DELETE FROM D WHERE ROWID IN (
SELECT DISTINCT MIN(ROWID) FROM D
WHERE DEPTNO IN
(SELECT DEPTNO FROM D GROUP BY DEPTNO
HAVING COUNT(DEPTNO)>1))

Is This Answer Correct ?    1 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to insert multiple rows with one insert statement in oracle?

1075


what is Single Byte Overhead...?

2548


How to create an oracle database manually?

1072


Describe the types of sub query?

991


How to get maxsal , minsal, ename department wise in single query

1543


Why does Oracle not permit the use of PCTUSED with indexes?

2417


How to drop an index in oracle?

1061


What is key preserved table?

1011


What is recovery manager in Oracle?

1048


interview questions with answer for cts

2578


What is dynamic proxy?

999


What is a procedure in oracle?

1176


How to unlock the sample user account in oracle?

1004


How to connect asp pages to oracle servers?

1068


You have found corruption in a tablespace that contains static tables that are part of a database that is in NOARCHIVE log mode. How would you restore the tablespace without losing new data in the other tablespaces?

1915