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 are the benefits of datastage?
Can you define merge?
Explain Quality stage?
What is "fatal error/rdbms code 3996" error?
What is usage analysis in datastage?
What are the types of containers and how to create them?
Source has 2 columns: USA,NewYork INDIA,MUMBAI INDIA,DELHI UDS,CHICAGO INDIA,PUNE i want data in target like below: INDIA,MUMBAI1 INDIA,DELHI2 INDIA,PUNE3 USA,NEWYORK1 USA,CHICAGO2
How to Remove Duplicate using SQL?
Name the different types of Lookups in Datastage?
How do you start developing a datastage project?
What is difference between server jobs & parallel jobs?
How a source file is populated?
EXPLAIN SCD
how to achieve this output ? Two Input columns(ID & Name) - ID | Name 1 | Jack 1 | Kara In output there should be only 1 column which will be populated as - 1,Jack 1,Kara
Which algorithm you used for your hashfile?