I have 2 Files like
fileA fileB Output1 Output2 Output3
1 6 1 6 11
2 7 2 7 12
3 8 3 8 13
4 9 4 9 14
5 10 5 10 15
6 11
7 12
8 13
9 14
10 15
please let know
Answer Posted / radhika m
Add an extra column 'colA' and 'colB' to the files 'A' and 'B' respectively. Let the value for colsA be 'a' for all the rows in file 'A' and the value for colB be 'b' in file 'B'(using the column generator stage).Now join both the files using join stage using 'ID' column. Perform full outer join. Map the ID col, colA and colB to output. Next pass it through a transformer.
Transformer constraint:
1) file X - colA=a and colB<>b ----->[1,2,3,4,5]
2) file Y - colA=a and colB=b------->[6,7,8,9,10]
3) file Z - colA<>a and colB=b------>[11,12,13,14,15]
Drop cola and colB in the output.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How do you reject records in a transformer?
What are routines in datastage?
What are the partitioning techniques available in link partitioner?
What is usage analysis in datastage?
Whats difference betweeen operational data stage (ods) and data warehouse?
what is repositery?
hi.... am facing typical problem in every interview " I need some critical scenarios faced in real time" plz help me guys
What is datastage engine?
What are the some differences between 7.x and 8.x version of datastage?
What are the different kinds of views available in a datastage director?
What is the flow of loading data into fact & dimensional tables?
Field,NVL,INDEX,REPLACE,TRANSLATE,COLESC
Differentiate between Symmetric Multiprocessing and Massive Parallel Processing?
Define Job control?
What are the various kinds of containers available in datastage?