TALEND SCENARIO: FIND SECOND HIGHEST SALARY IN A DEPARTMENT

 FIND SECOND HIGHEST SALARY IN A DEPARTMENT

Job Design Screenshot:



Source Code : Download

1. Write input in Fixed Flow input component

2. Sort Data on column DeptID and Salary 

3. Use Numeric.sequence(row2.DeptName.toString(),1,1)  in tMap to groupBy DepatName and add sequence number by department



 4. Filter the data on column Seq using the tFilterRow component

5. You will get the second-highest salary by Department





2 comments:

  1. How is the sequence reset for each value of the row2.DeptName.toString()?Is this a by-default behaviour?

    ReplyDelete