The SAP HR module is the only module that still utilizes logical databases. For good reason: it has added value - mainly because of the timely fashion (information has a validity period) data is maintained in the system. Every bit of HR information (held in infotypes) has a start and an end date.
When you are using an organisational plan (transaction PPOME
), the hierarchy is locked into the relations table HRP1001
. This is not a very simple but straightforward setup where the relations in both directions are described. Here's how to access this information from your Abap.
So your user is the manager and you need to know who is being managed ? Here's a 2-step approach to this using function module HR_STRUC_GET
or HR_STRUCTURE_GET
on newer systems, accessing a great variaty (700+) of evaluation paths. Who's on my team ?
What's a harvester ? It's a report that runs reports and gathers their output. This article describes a harvester report that runs a standard SAP report for a series of Legel persons. The ALV output is scooped up and the output of the combined report runs is reported or stored in a file. Complete turn-key example available !
Information about the employee can be readily available via function modules, here's a listing of some of the more commonly used function modules for retrieving employee information:
Partnerships between object ID's are described in infotype 1001 and 1055, which can be found in tables HRP1001
and HRP1055
. This article shows how these tables can be manupilated.
HR is a module that has done things differently since day 1. Cluster data is no exception and when you are asked to bring it on, you may want to remember reading this article.
For some of the infotypes, the system expects additional infotypes to be made available. Thus e.g. for infotype 0002 the additional infotype 3346 is expected to be available for English employees. If for some reason it is not, update modules (like RFC module IDENTITY_MODIFY
) may start to complain. Use report RPUPAV00
to check and/or solve these missing infotypes errors. The report will check also the very country specific additional infotypes and report them as well as add them. Handy !
Article predades the millenium bug...
Any bit of coding that is done repetitively can be set up in a macro, with DEFINE .. END-OF-DEFINITION
within any Abap coding source. This article is about another type of macro, which is much less well known. The Macro module or RMAC macro can be set up centrally on the system, so it can be called from anywhere.