Employee Hierarchy using talend

Highlighted
Six Stars

Employee Hierarchy using talend

Hello All,

 

I was trying to get the employees reportees list as (Ex: - A|B|C|D|E)

 

I am a newbie to talend, so i was little consfused about what are the components to use, and how to use, what sort of java code that i have write( zero knowledge of java Smiley Happy ).

So i thought i could get help from the community.

 

Now coming to the problem statement.

Sample Data:- 

EmpID|Name|ManagerID

10110
102B11
10C1
11D1
1Enull

 

1:- get the employees reportess as below.

EmpID     Name           Path
   101         A         101|10|1
   102         B         102|11|1
   10          C         10|1
   11          D         11|1
   1           E         1

 

Please help.

 

Thanks in advance.

Mohan V.

 

Highlighted
Six Stars

Re: Employee Hierarchy using talend

Is talend community is helpful.???

Highlighted
Five Stars

Re: Employee Hierarchy using talend

I am facing with the same scenario in my work using Talend. Expecting an answer for the same.

Highlighted
Six Stars

Re: Employee Hierarchy using talend

I was facing the same issue, i found a way to simplify the process with Oracle DB function CONNECT BY.

 

You can have the level with LEVEL.

You can specify the start (CEO, KING, TOP hierarchy) of your hierachy with START WITH.

You can get all the leaf (end of a branch of the tree) with CONNECT_BY_ISLEAF (1 = Leaf = no one after this person, 0 = Branch).

You can get the path (King/Prince/Someone1/Someone2, etc) with SYS_CONNECT_BY_PATH(name, '/') "Path".

 

I suggest you to do a data preparation with the database. In Oracle there is the function CONNECT_BY (https://docs.oracle.com/cd/B19306_01/server.102/b14200/queries003.htm) used for hierachical queries. It will do all the preparation, then you just have to test the level returned by the query in Talend.

 

Hope it will help.

2019 GARTNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

Introduction to Talend Open Studio for Data Quality

Find out about Talend Open Studio for Data Quality

Watch Now

Enabling Data Governance

Learn how to enable Data Governance

Watch Now

The Definitive Guide to Government Data Quality

Take a peek at the definitive guide to Government Data Quality

Read