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...

What is the SQL query to select, delete and get count of
duplicate rows in DB2?

Answer Posted / hkhatri27

SELECT Columns
FROM Table
GROUP BY Columns
HAVING COUNT(*) > 1;

~ Himanshu

Is This Answer Correct ?    2 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

run jcl for cobol+db2 pgm?.. //jobcard //step001 exec pgm=ikjeft01 //systin dd * DSNSYSTEM(--------) RUN PROGRAM(MYPGMNAME) PLAN(-----), LIB(-------), PARMS(------) /* WHAT WILL U GIVE INSIDE THE BRACKETS... WHAT IS PLAN,PACKAGE,BIND?..PLAN N PACAKGES ARE GENERATED BY ?...

4213


What's The Error Code For Unique Index Voilation?

1152


How do I import data from excel to db2?

1011


What is performance tuning db2?

1006


How does a cursor work?

928


How to get the ddl of a table in db2?

1071


What db2 400?

1103


What is image copy in db2?

943


What is drop table?

958


In an sql table that is embedded, what is the procedure to retrieve rows that are part of a db2 table?

1048


What is the purpose of rollback and commit?

1085


What are bind parameters in db2?

980


What is db2 instance?

1015


Is it possible to alter a table – for example adding a column, when another user is accessing or updating some columns?

1029


What is meant by union and union all?

948