In the source seq file have 2 columns, i.e
input:
col1,col2
1,1
2,rajesh
3,15000
4,2
5,suresh
6,16000
7,3
8,veeru
9,17000
I want in the output like:
eno,ename,sal
1,rajesh,15000
2,suresh,16000
3,veeru,17000
any one answer this scenario
Answer Posted / subhash
SRC--->TFM--->PIVOT----> TGT
In TFM, use below logic
col1 MOD 3----->col1
then out from TFM is:
col1,col2
1,1
2,rajesh
0,15000
1,2
2,suresh
0,16000
1,3
2,veeru
0,17000
In PIVOT, do vertical PIVOT, group by column is 'col1' and pivot column is 'col2' then we will get desired output.
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
What is process model?
What is the method of removing duplicates, without the remove duplicate stage?
What are the types of hashed files in data stage
What is the difference between passive stage and active stage?
What is datastage?
Explain connectivity between datastage with datasources?
What is a datastage job?
Name the third party tools that can be used in datastage?
In a batch if a job fails in between and you want to restart the batch from that particular job and not from the scratch then what will you do?
1)s.key generate 1 to 700 records today. tomorrow another 400 will updated how to update the records using s.key generator? 2)source is like :-- DB --> T/F stage1 --> seq1file T/f 1 is linking with T/F2 ---> seq 2 how to load the data? in source i given some conditions those r going in seq1. The another data will going to seq2 how to do this ?
How to read multiple files using a single datastage job if files have the same metadata?
What are stage variables and constants?
Why do we use link partitioner and link collector in datastage?
In work load management there are three options of Low priority, Medium priority and High Priority Jobs which can be used for resource management. why this feature is developed when there is already jobs prescheduled by scheduler or autosys. what will be the use of workload management then?
What is the difference between datastage and informatica?