cancel
Showing results for 
Search instead for 
Did you mean: 

How to get reporting line of an employee?

Former Member
0 Kudos

Hi gurus,

Given a PERNR, I need to get the reporting line of the person, from his/her direct manager to the top level of this commpany. How to achieve that? Is there any function module for it? I looked for it in SE37 but nothing found. thanks in advance.

regards,

Xiaoming

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

You can achieve through Function module -RH_STRUC_GET

Manoj.

sikindar_a
Active Contributor
0 Kudos

ohhh

thanks sir it is RH_STRUC_GET

As usual for correcting me

Former Member
0 Kudos

Nope siki..

I ddnt notice that dude..

Call this FM twice

Pass emloyee position to the FM with relation (A002) to the get the managers position .

Pass the position to get the Holder (realtion -008) .

Manoj.

sikindar_a
Active Contributor
0 Kudos

i never mind manoj as your one of the best Mentor in SDN

Former Member
0 Kudos

Hi Manoj,

thanks for the answer. the function module requires a parameter of evalution path. Do you konw an system evaluation path for reporting structure? I guess a path like P-S-S-P works and I am going to try.

However, one point I am not sure is, when we say a PERNR A is manager of another PERNR B, how is it configured in system? I see 2 options:

1. position of A has a relationship "is manager of" to position of B.

2. position of A "is manager of" the org unit which incoprates the position of B.

which one is correct? or both fine?

thanks & regards,

Xiaoming

Former Member
0 Kudos

Thanks Siki .

@Xiaoming,

Hope ur Issue is solved .

Cheers,

Manoj.

Former Member
0 Kudos

First One.

Both are fine.One is bottom to top relation and other vice versa.

Check thru PPOSE

For your req,

First Position A has a relation " Reports (line) to " position B( Manager) - RElation -A002.

The position B has a relation ""Holder" to personal Number - Relation -A008.

Manoj.

romanweise
Active Contributor
0 Kudos

Hi,

in most cases the manager of an employee is the employee assigned to the position which is marked as leading position for the org. unit or an org. unit above, if there is no leading position in the org. unit directly. But there are other approaches possible, like using customer relation types.

You should check PPOME to varify how it is handled in your company. You should also check if P objects are assigned to positions (S) or central persons (CP) are. I even saw users assigned to positions. Depending on what you find, you can get the path from pernr to the pernr of its manager. PPOME in combination with HRP1001 is very helpfull here. The result might be P of employee is related via B008 to its position (S), position related to org unit via A003, org units among each other (O) bottom up via A002, org unit related to leading position via B012, and this position related with the pernr of the manager via A008.

RH_STRUC_GET is for evaluating structures. So you do not need to get every single relation step by step. You just build your evaluation path based on what you need (or use an existing if possible). So you get the whole structure of all managers of an pernr (the O->O relation ensures that not only the current org. unit is processed) in one call, no matter how deep your organizational structore is.

Best Regrads

Roman

Answers (1)

Answers (1)

sikindar_a
Active Contributor
0 Kudos

Try

RH_GET_STRUC in SE37

for SE16 Check HRP1001 and check the relationship