Input: Emp - ID Dept - ID Salary

You might also like

Download as xlsx, pdf, or txt
Download as xlsx, pdf, or txt
You are on page 1of 3

Populate highest, lowest and average salary by taking below input source data

Input:
Emp_ID Dept_ID Salary
40 200 40000
20 300 30000
70 200 50000
60 100 20000
50 300 35000
30 100 70000
10 200 60000
80 300 45000
90 100 75000

Output:
Dept_ID Emp_ID Salary Performance
200 40 40000 Lowest
300 20 30000 Lowest
200 70 50000 Average
100 60 20000 Lowest
300 50 35000 Average
100 30 70000 Highest
200 10 60000 Highest
300 80 45000 Lowest
100 90 75000 Highest

Source -> Sorter (Sort on Dept Id) -> Aggregator (Group on Dept Id and Calculate the Max and Min
Salary for each Department) - > Joiner (Join the original data with the output of Aggregator on Dept
Id ) -> Expression (Create a Performance Output column and calculate as per the requirement logic)
-> Target (Populate everything in the target excluding the Max Salary and Min Salary columns)
There are two Input Files. Transform the source datasets as per the Output.

Input File A: Input File B:


Cust Id Cust Name_A Cust Id Cust Name_B
101 Ben 103 Harry
102 Jennie 104 Cristina
103
104

Output:
Cust Id Cust Name
101 Ben
102 Jennie
103 Harry
104 Cristina

Input File A Detail


Input File B Master

Perform a Master Outer join to get all the rows from


Detail and then use and Expression transformation to
populate Cust Name column

Joiner Output:
Cust Id Cust Name_A Cust Name_B
101 Ben
102 Jennie
103 Harry
104 Cristina
.

You might also like