write a sql query following table some duplicate present
1
1
2
2
3
3
4
5
i want the output unique one column duplicate another
column following format like
unique duplicate
1 1
2 2
3 3
4
5
Answers were Sorted based on User's Feedback
Answer / babu
Hi,
SELECT DISTINCT(DEPTNO) UNIQ,E.DUP FROM EMP
LEFT OUTER JOIN
(SELECT DEPTNO DUP FROM EMP GROUP BY DEPTNO HAVING COUNT
(DEPTNO)>1) E
ON (EMP.DEPTNO=E.DUP)
please correct me if any thing wrong.
Thanks,
Babu
| Is This Answer Correct ? | 2 Yes | 0 No |
Answer / nagarau puppala
select distinct country_id "unique", (case when count(country_id) > 1 then country_id else null end) "duplicate" from s_region
group by country_id order by duplicate;
| Is This Answer Correct ? | 3 Yes | 4 No |
How to eliminate duplicates in FF and oracle both
why do u use shortcuts in informatica.?
How to import oracle sequence into Informatica?
If u select groupby port in aggregator what is output and dont select groupby option what is output
i have 2 session s1 execute s2 load first session fail what is the reason?
Hi all , I am planning for informatica S - PowerCenter 8 Mapping Design certification. I have rewuired the dumps for the same. if anyone of you having the same pl. share it with me. This will be of great help. My contact is : sagardev7@gmail.com TIA , Sagar
Which means the first record should come as last record and last record should come as first record and load into the target file?
I am Unable to load the FixedWith FlatFile Into The Target.What Is The Reason. PLZ Help Me..
can you use flat file for lookup table?why?
What are the different types of Type2 dimension maping?
i have two flat files.. containing same type of data i want to load it to dwh..how many source qualifires i need
can we use cartesian join in informatica