Hi Everyone,
In SAP payroll we often get requirement to calculate salary when employee is on halfday unpaid absence. Recently I have implemented the rule for one of my client where I came across the following requirement:
 A single absence type to be used for full day and half day unpaid absence.
 The planned working hours are different for different employee groups depending on their work schedule rules.
Since we can not calculate on 0.5 calendar days or absence days, we need to convert the working days to working hours for reducing the absence hours and again we need to reconvert from hours to days which shown in below PCR.
To achieve the calculation we have created unpaid absence type from time management configuration.
I have copied standard PCR GPP1 and created my own PCR ZGPP which is placed in GPP0 for factoring calculation
I am considering factoring wagetype /801 for calculation partial period as my wagetype has specification ‘1’ in processing class 10.
Followings are the codes written in custom PCR ZGPP
Code  Explanation 
RTE=TKSOLL

** Stores the calendar days for current month in Rate field 
NUM=TSSOLL

** It stores the employee’s monthly working hours for current month in NUM field 
NUM/TASOLL

** This line divides the total working hours by the total working days to get the daily planned working hours 
MULTI RNR

** This line multiplies the calendar days with the daily working hours to get the total calendar hours for this employee 
RTETSAU**

** This line reduces the unpaid absence hours from the planned working hours 
DIVID RNR

** This line divides the total reduced working hours by the daily working hours to convert the calculation into days 
RTE*KGENAU

** This line multiplies the value with 10000 which is stored in table V_T511K as constant 
RTE/TKDIVI

** This line divides the value with monthly working days 
ADDWT *

** The value added to wagetype /801 
I have entered PRINT command in the PCR to explain the calculation line by line with example:
Taking example of an employee who’s planned daily working hour is 7 and applied unpaid leave for 3.5 hours in April 2020
The employee’s monthly salary is 5000.00 GBP.
So the salary should be paid to him after deduction is : 5000((5000/30)/2) = 4916.67 GBP
I have executed payroll and expanded the calculation rule in payroll log:
Below is the payslip with reduced salary for half day:
I have explained the calculation rule for generating value in wagetype /801. The wagetype then passed to PCR GVAL to calculate the total salary to be paid.
If anyone interested to know about the PCR GVAL please leave you message comment section I will explain in my next blog.
Appreciate your feedback or suggestions.
Good Post which will be helpful to all the new bees in Payroll.
Partial period hours will be calculated in SAP, for that we need to convert the hours into days by changing the PCRs which you have done.
Can you please check if the following is working in the following scenarios.
by the above testing, we can come to a clear picture on system behaviour In whole.
Hi Sikindar,
Thank you for your valuable comment. Yes, this is working for Mid month split scenarios and to do so I have edited the divider factor from TKSOLL to TKDIVI. Thank you once again.
Hi Pampa,
Thank you for writing such a nice blog. How we can make it work of those week off as per work schedule where client is giving LOP on the weekoff as the absence hours on such type is 0.
Regards
Manish Garg
Really nice with proper explanation…
Siddhartha