Unlike other modules data processing in SAP , HR module data processing is little bit different. Here the resultant data will be stroed in Clusters , which we can not access directly with normal select satments . One have to use the SAP provided methods only for data accessing. So I thaught the below program will help a little for HR ABAPers who are learning now.
Below is the program to retrieve an employee's last run payroll results. For this program I used PNP LDB .
PROGRAM:-
| Program Source Code |
|---|
REPORT ZR_CSD128. ** Triggering of Get Event. ** Call the function module to import the cluster directory table for the an employee coming in Get pernr Event.
** Call the FM to get the latest run payroll results Sequnce number. CALL FUNCTION 'CD_READ_LAST' ** Once if you are ready with the Sequence number for a particular employee call the FM to import Payroll results into Deep structure ( ST_PAYRESULT).
** RT table is meant for stroing Result data of the particular Payroll run. LOOP AT ST_PAYRESULT-INTER-RT INTO WA_RT WHERE lgart = '/560'. " /560 is the wage type for Net Salary. ** End of Program. |
And the Final output will be like as below.

Regards,
Mayure.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 6 | |
| 6 | |
| 5 | |
| 4 | |
| 3 | |
| 3 | |
| 3 | |
| 3 |