How to show all duplicate rows in a table?

Showing Answers 1 - 6 of 6 Answers

Nilesh Rathod

  • Mar 17th, 2015
 

Simply Using group by and having clause...

Code
  1. SELECT

  2.     Col1, Col2, COUNT(*)

  3. FROM

  4.     Table1

  5. GROUP BY

  6.     Col1, Col2

  7. HAVING

  8.     COUNT(*) > 1

  Was this answer useful?  Yes

Nilesh Rathod

  • Mar 17th, 2015
 

Simply using group by and Having clause.

Code
  1. SELECT

  2.     Col1, Col2, COUNT(*)

  3. FROM

  4.     Table1

  5. GROUP BY

  6.     Col1, Col2

  7. HAVING

  8.     COUNT(*) > 1

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions