how to find find & delete duplicate rows from two different
tables?
Answers were Sorted based on User's Feedback
Answer / pravin jadhav
delete from table_name where rowid not in (select max(rowid) from table group by
duplicate_values_field_name);
or
delete duplicate_values_field_name dv from table_name ta where rowid <(select min(rowid) from
table_name tb where ta.dv=tb.dv);
| Is This Answer Correct ? | 6 Yes | 0 No |
Answer / paks
using rownum .
Select * from
(Select name,id, Row_number () over (partition by name order by id desc) rn from tblname)
Where rn=1;
| Is This Answer Correct ? | 2 Yes | 3 No |
Answer / k.sailesh
We can find duplicate rows from two tables by using select *
from table name. it displays all the values repeated and unique.
We can delete duplicate rows by using Primary key constraint.
| Is This Answer Correct ? | 3 Yes | 17 No |
what are different types of deletes?
What is the difference between PFILE and SPFILE in Oracle?
consider some table with 4 r 5 columns in that 1 col is DATE type. The data is like that,For each date in that col some 3 fields r there but all the records r having different data. Now i want to display all the columns by performing grouping on the date field ( as SELECTION Operator(*) cannot be used with group function having only one "group by clause". how to do this? can any one help me in finding out the solution plss?
How to call a sub procedure?
How will you identify oracle database software release?
How to write text literals in oracle?
What is the cache hit ratio, what impact does it have on performance of an Oracle database and what is involved in tuning it?
What is Database Link ?
what is reindexing?
What happens if you use a wrong connect identifier?
what is the difference between joins and set operators.i am always confusing with two,can u pls kindly help me .
Explain index?