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 the command line function to import and export the ds jobs?
What are stage variables, derivations and constants?
how do u catch bad rows from OCI stage? And what CLI stands for?
What is the difference between operational data stage (ods) and data warehouse?
Can you explain players in datastage?
What are some different alternative commands associated with "dsjob"?
How do you import and export the datastage jobs?
How can one find bugs in job sequence?
Name the different sorting methods in datastage.
Is possible to create skid in dim,fact tables?
Define Routines and their types?
AGGREGATOR default datatype
How to create a file using vi editor? 2)how to delete a file in vi editor? 3)How to connect the server datastage to unix? what r the command lines we r using? 4)30 jobs r runnig in unix i want to find out my job. how to do this? give me command?
What are the repository tables in datastage?
Differentiate between odbc and drs stage?