Write an SQL Query to
Delete Duplicate records from a table using ROWID.

Answer Posted / ankit kumar srivastava

DELETE FROM EMP_a WHERE ROWID NOT IN(
(SELECT MAX(ROWID) FROM EMP_a a GROUP BY
EMPNO,ENAME,sex,doj,sal,deptno,mgr HAVING COUNT(ROWID)
=1)
UNION
(SELECT MAX(ROWID) FROM EMP_a a GROUP BY
EMPNO,ENAME,sex,doj,sal,deptno,mgr HAVING COUNT(ROWID)>1))

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

tell me the scenarios of the independent in reports

2053


What is a flexfield? List out its types.

669


Explain oracle apps architecture.

767


is it possible to run the interface without using oracle apps?

1519


How to create a purchase order without a requisition?

632






What are do's and dont's of Interface?

1905


Are you familiar with internet architecture of oracle apps 11i?

632


Tell me how to debug the report?

642


tell my any difficult situtation you solved in your experience in your company?

1869


Can you define an erp system?

682


Explain what are the tables of auto invoice?

650


Do you know what is applysys in oracle application database schema, what is apps?

677


Hi, Anybody please send me the Oracle APPS 1i technical interview questions (Real time) as wel as sample resume also?

2131


Do you know what are user profiles in apps. Any examples you can give?

665


Can you explain the difference between architecture followed in 10g & 11g?

666