How to display all the duplicate records from the oracle
Table?
Answers were Sorted based on User's Feedback
Answer / raghunath
select empno from emp group by empno having count(empno)>1;
it is working.
| Is This Answer Correct ? | 10 Yes | 1 No |
Answer / nagam
select count(*),empno from emp group by empno having count(*)>1;
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / prasad
select * from Table_name where column_name in(select Column_name from table_name group by column_name having count(1)>1)
select deptno from emp where deptno in (select deptno from emp group by deptno having count(1)>1)
u will get only duplicate records
for Example:
deptno
----------
10
10
20
20
30
40
50
by using above query the o/p displays
deptno
--------------
10
10
20
20
| Is This Answer Correct ? | 0 Yes | 0 No |
What is a quality stage?
tell me 5 situations when we r using oracle db stages like orecle connector, oracle enterprise
Highlight the main features of datastage?
What are some different alternative commands associated with "dsjob"?
How will you move hashed file from one location to another location?
In one project how many shared containers are created?
How to display all the duplicate records from the oracle Table?
What are the different database update actions available?
How can remove duplicates in a file using UNIX?
how many types of sorting the data in data stage?
how to change left and right links in join stage?
whom do you report?