How to retrieve Duplicate Rows only in a Table?
Suppose if a Table Name is "Education". It consists of
multiple columns. Then if we insert rows into this table
with duplicate records then how can we retrieve only
duplicate records from that table?

Answer Posted / seshu

SELECT RNO,NAME,COUNT(*) REP_COL FROM Education GROUP BY
RNO,NAME having Count(*)>1;

Is This Answer Correct ?    7 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Does a primary key have to be a number?

522


Is left join inner or outer by default?

523


Can we call a function containing dml statements in a select query?

546


what are ddl statements in mysql? : Sql dba

579


Is sql sequential or random?

541






What is scalar function in sql?

531


What is cross join example?

556


Is sql a scripting language?

521


Is pl sql and postgresql same?

573


Why do we use subquery?

489


how to calculate the difference between two dates? : Sql dba

550


Why do we need cursor in pl sql?

651


What is crud stand for?

570


What do you mean by query optimization?

551


What are reports usually used for?

568