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 / sarath
I don't know the exact intention of the above answers, but I am making mine clear that to find the TOTAL DUPLICATED RECORDS and THEIR COUNT OF REPETITIONS, the Pseudo code is:
Select col1,col2,col3,....,COLn count(*) from <TN>
group by col1,col2,col3,....,COLn having count(*) > 1;
Wish everybody complies with it, its tested.
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is the execution plan in sql?
Is t sql a programming language?
What is varchar used for?
What does an inner join do?
What is fmtonly in sql?
Why commit is not used in triggers?
what is 'mysqlshow'? : Sql dba
Is left join same as join?
Explain commit, rollback and savepoint.
What are the two parts of design view?
what are the different index configurations a table can have? : Sql dba
what are date and time data types? : Sql dba
How do you create a unique index?
how to use myisamchk to check or repair myisam tables? : Sql dba
How many commands are in sql?