Suppose there are many duplicate records in a Db2 table.
What is the query to retrive only duplicate records?
Answer Posted / azharuddinsyed
SELECT <COLUMN_1> FROM TABLENAME
GROUP BY COLUMN_1
HAVING COUNT(COLUMN_1) > 1
OR
SELECT <COLUMN_1> FROM TABLENAME
GROUP BY COLUMN_1
HAVING COUNT(*) > 1
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How to restart a DB2 program?
What is the function of logging in the db2 database?
My sql statement select avg(salary) from emp yields inaccurate results. Why?
Is ibm db2 open source?
What are the bind parameters ibm db2?
What is database alias db2?
What is the result of open cursor statement?
What is db2 catalog database?
Explain the contention situations caused by locks?
What is nvl in db2?
How do I create a view in db2?
What is buffer pool and list some of them?
What is db2 connect?
How to check last update on table in db2?
What is sqlca?