Source Like
department_no, employee_name
----------------------------
20, R
10, A
10, D
20, P
10, B
10, C
20, Q
20, S
and Output should be like this
department_no, employee_list
--------------------------------
10, A
10, A,B
10, A,B,C
10, A,B,C,D
20, A,B,C,D,P
20, A,B,C,D,P,Q
20, A,B,C,D,P,Q,R
20, A,B,C,D,P,Q,R,S
Answer Posted / subhash
small modification to the above ans:
SRC---->Transformer--->TGT
we do the 'HASH' partitioning on Dept_No.
SetNull value to the Stage variable----->SV_List
In the transformer stage variables:
SV_List :',' : Employee_Name ----->SV_List (Concatenating Employee
Names)
In the Column Derivation:
TRIM(SV_list, ',' , 'L')------->Employee_Name
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
What could be a data source system?
What is the difference between an operational datastage and a data warehouse?
What is the method of removing duplicates, without the remove duplicate stage?
Define Routines and their types?
If you want to use a same piece of code in different jobs, how will you achieve this?
What are the main features of datastage?
Define Job control?
how to get sum of sal based on dept_no and then sum of all sal irrespective of dept_no in same sql. output:- 10, 200(sum of sal for dept_no 10), 5000(sum of all sal)
What are the types of hashed files in data stage
In Datastage, how you can fix the truncated data error?
Enlist various types of routines in datastage.
Does datastage support slowly changing dimensions ?
what is the difference between == and eq in UNIX shell scripting?
Can anyone tell me a difficult situation who have handled while creating Datastage jobs?
Describe routines in datastage? Enlist various types of routines.