I have 2 files 1st contains duplicate records only, 2nd file contains Unique records.EX:
File1:
1 subhash 10000
1 subhash 10000
2 raju 20000
2 raju 20000
3 chandra 30000
3 chandra 30000
File2:
1 subhash 10000
5 pawan 15000
7 reddy 25000
3 chandra 30000
Output file:-- capture all the duplicates in both file with count.
1 subhash 10000 3
1 subhash 10000 3
1 subhash 10000 3
2 raju 20000 2
2 raju 20000 2
3 chandra 30000 3
3 chandra 30000 3
3 chandra 30000 3
Answer Posted / subbuchamala
File1,File2====Funnel-----Copy=======1st link AGG, 2nd link JOIN----Filter----OutputFile
1. pass the 2 files to funnel stage and then copy stage.
2. from copy stage 1st link to AGG stage, 2nd link to JOIN stage
3. In AGG stage, Group by Key column say ID, NAME take the count and JOIN based on KEY column
4. Filter on COUNT>1 send the output OutputFile
we get desired output
| Is This Answer Correct ? | 14 Yes | 0 No |
Post New Answer View All Answers
What are the processing stages?
What is the difference between hashfile and sequential file?
Does datastage support slowly changing dimensions ?
Is it possible to query a hash file?
What are the partitioning techniques available in link partitioner?
What are system variables and sequencers in datastage
Can you define merge?
What are the types of containers and how to create them?
Explain how a source file is populated?
What is process model?
What is a folder? Difference types of stages?
What all are the different way to run a job?
How many Key we can define in remove duplicate stage?
Define Merge?
what is ds administrator used for?