You are on page 1of 4

Generated by Jive on 2014-08-06+02:00

1
SAP ERP HCM Employee Self-Service:
Function Module to get subordinates of a
manager
Posted by Dhiraj Pednekar Oct 14, 2013
Unfortunately, I have seen generally that there is no proper standard FM provided by SAP where you can
get the subordinates of a manager to directly. So, I got curious enough to explore more on this one & started
debugging & troubleshooting different set of services like Team Calendar, Team Viewer etc. in backend. And I
indeed found one which could be used more realistically for getting subordinates related data.

Although there are other FM's like RH_STRUC_GET which can also be used, but they are more complicated
to use by way of passing input & changing parameters to them. So, one FM that can be queried very easily &
get the required set of data is 'HRWPC_RFC_OADP_GET_OBJECTS'. This FM has been primarily been used
as a wrapper FM for most of the services in MSS viz., Team Calendar , Team Viewer to name a few.


Parameters that needs to be passed to this FM are :-

OBJSEL -> Either of the two values can be passed depending on the business needs.
1. MSS_TMV_EE_DIR -> This will only give DIRECT REPORTS to the manager , as per the
evaluation path of O-S-P.
2. MSS_TMV_EE_ALL-> This will give ALL EMPLOYEES coming under the manager , as per
the evaluation path of O-S-P
(Both the above parameter values are based on OADP- Object and Data Provider structures used
in MSS)

BEGDA -> SY-DATUM

ENDDA -> SY-DATUM

USER-> Username of the manager stored in info type 0105.


An example to depict the working of this FM is shown from the below Organization Structure .



SAP ERP HCM Employee Self-Service: Function Module to get subordinates of a manager
Generated by Jive on 2014-08-06+02:00
2





Passing object selection MSS_TMV_EE_DIR


SAP ERP HCM Employee Self-Service: Function Module to get subordinates of a manager
Generated by Jive on 2014-08-06+02:00
3

Passing object selection MSS_TMV_EE_ALL

As you can see, in the last result an additional employee is outputted as "Bryan Adams" , as he not being the
direct employee of the manager.
SAP ERP HCM Employee Self-Service: Function Module to get subordinates of a manager
Generated by Jive on 2014-08-06+02:00
4

Hope this blog was helpful for those who usually gets baffled for getting subordinates data of a manager
through various discussion forums.




1785 Views Tags: enterprise_resource_planning, sap_erp_human_capital_management
Saurabh Gupta
May 20, 2014 12:33 PM
Excellent Work Dhiraj..
Pradyp Parakala
Mar 24, 2014 8:22 AM
Gr8 work Dheeraj

keep coming with more such docs..

Cheers
Pradyp
Sarath Babu
Mar 11, 2014 11:31 AM
Thank you very much for providing a one time solution to the problem which we were facing for quite
some time. Most the times we needed to traverse along the org hierarchy to bring out employees reporting
to a manager. Now this FM provides an easy solution and seems like a great time saver . I presume
the entries in the parameter 'OBJSEL' corresponds to the 'Selection' parameter maintained in the view
'V_TWPC_OBJSEL'.
Siddharth Rajora in response to Steve Oldner on page 4
Dec 3, 2013 10:24 PM
did you try these FMs RH_GET_ORG_ASSIGNMENT
or RH_GET_MANAGER_ASSIGNMENT?
Steve Oldner
Dec 3, 2013 7:12 PM
Very nice writing and good, clear examples.

You might also like