Human Capital Management Blog Posts by Members
Gain valuable knowledge and tips on SAP SuccessFactors HCM suite and human capital management market from member blog posts. Share your insights with a post of your own.
cancel
Showing results for 
Search instead for 
Did you mean: 
StephanieBM01
Participant
1,065

If you enjoy my blogs, please let me know by clicking on the Kudo button just above! Your support inspires me to write more.

 

Introduction: The Challenge

Recently, my friend Alex, a compensation consultant, approached me with an interesting problem. He said, "Stéphanie, I have a client who needs to determine the percentage of yearly presence for compensation purposes, so I can pro-rate the compensation calculation based on their presence rate. Can you think of something?" To which my response was, "Challenge accepted!"

In this blog, I'll share the Proof of Concept (PoC) I developed for Alex. It calculates the total number of days of absences (from time-off) and the presence rate for each employee for a specific year. Once this data is made available (in a custom object), Compensation Planning can work its magic with it. Although, to my knowledge, this PoC was not implemented, I thought it was too cool not to share and let it sit on a shelf!!

 

Solution: Version Simple

The solution is straightforward. I'll assume that if you're reading this blog, you have a basic understanding of creating custom MDF objects, rules, and attaching them to the object. So, let's skip to the important and fun stuff!

What I'm proposing is creating a custom MDF object (without an effective date). We'll add two decimal fields to it: one to store the number of absences in days (this field is technically optional, but it helps to explain the concept when both fields are visible) and another to store the attendance rate for the previous year (in this case, 2024), as shown below:

StephanieBM01_0-1744765618185.png

 

Once the object is created, you can add it to your People Profile (or, in my case, the Full Profile — how modern of me in early 2025! 😄).

Next, it's essential to know which rule functions are available. It's always a good practice to review the "Implementing Business Rules in SAP SuccessFactors" guide periodically, especially the Function A-Z section, or to check the Change History section for new features (yes, I really do that).

Let's try using a function that seems appropriate for this case and see the results. (Remember, this is a proof of concept—there might be a better function to use, but this one will do the trick for now!):

 

Count Number of Leave of Absence Days()This function calculates the number of days for a given period of time.

 

Let's build our rule for 2024. In the first field, we'll count the number of days of absences in 2024. In the second field, we'll calculate the "Presence Rate," which is defined as:

StephanieBM01_1-1744765618186.png

where the Absence Rate is calculated as:

StephanieBM01_2-1744765618187.png

 

StephanieBM01_3-1744765618200.png

And then let’s assign our rule On Save in our beautiful custom object (as shown in my first image). Time to test:

  1. Go to an Employee File check out our Absence Count object:
  2. Select Edit on the object
  3. And Save

StephanieBM01_4-1744765618222.png

Our Absence Count shows 0 days of absence and a presence rate of 1 (or 100% present). Great!

Now, let's test when adding an absence:

  1. Add an absence in our employee Time Administration Workbench
  2. Go back to our object and select Edit
  3. And Save

StephanieBM01_5-1744765618237.png

Our Absence Count was updated to reflect 31 days of absence (the entire month of December 2024), and the presence rate was adjusted accordingly. Good again! It seems to work well.

The last step is to make the object available for all employees who were present in 2024. This is quite simple: you just need to create an import file for our custom object with the employees' IDs. The "On Save" rules will be triggered during the import, updating all employees in the file with their absence count and presence rate. Here is a sample of a one-line import and the result:

StephanieBM01_6-1744765618252.png

 

Solution: Version Intermediary!

I presented the simple version of the solution to Alex, to which he replied: "But Stéphanie, can you exclude some absences from your count? I need more flexibility. Also, if an employee was hired during the year, can you count the period before they were hired as an absence?". To which my response was, "Ok then, challenge accepted…again!"

There are numerous rule functions available for handling absences in SuccessFactors, such as:

 

Get Absence Days()With this function, you can calculate how long an employee has been absent within one year for a specific time type.
Get Absence In Days For Period()This function calculates cumulated absence days for the given date period and a given time type.
Get Absence In Days For Period Based On Calendar Days For Time Types()This rule function calculates the total number of absence days in given duration for the time types provided.
Get Absence In Days For Period Based On Working Days For Leave Of Absence Time Types()This rule function calculates the number of absence days during a given duration for the given time types.
Get Absence In Days For Period Based On Working Days For Time Types()This function calculates the cumulated absence days for the given duration and given time types.
Get Absence In Days For Period Based On Working Days For Time Types Excluding Weekdays()With this rule function, you can exclude the weekdays of your choice when getting the sum total of absence days
Get Absence in Days For Period with Threshold()This rule function calculates the sum of absence days in a given period for the time types provided where individual Employee Time duration exceeds a given threshold value.
Get Absence In Days Or Hours For Period Based On Deduction Quantity For Time Types()This rule function calculates the total deduction quantity, in days or hours, for absences in a specified period and with the specified time types.
Get Absence In Hours For Period()This function calculates cumulated absence hours for the given date period and a given time type.
Get Absence In Hours For Period For Time Types()This function calculates the cumulated absence hours for the given duration and given time types.
Get Completed Months Of Time Types In Period()This rule function calculates the number of complete months for which the employee was absent in a given period for the time types provided.
Get Number of Absences for Period for Time Types()This function calculates the number of absences of a list of time types within a given period.

(my point being, you can do a lot with rules when you explore the available functions and experiment with them!)

The function to use to count days of absence for specific time type (absence) is Get Absence In Days For Period Based On Calendar Days For Time Types().

For employees hired in 2024, we'll count the days between January 1, 2024, and their hire date, adding this sum to our absence count.

I implemented these three calculations as variables:

StephanieBM01_7-1744765618267.png

Now, we'll set up two conditions:

  • For employees hired before 2024: We'll count their absences for specific time types and calculate the presence rate.
  • For employees hired during 2024: We'll add the hire pro-rata to our absence count.

StephanieBM01_8-1744765618278.png

Now, let’s test!

Paternity Leave (6003) is not included in our absence count. Let’s see the result of our object when an employee goes on Paternity Leave:

StephanieBM01_9-1744765618298.png

 

Long Term Disability (6001) is included in our absence count. Let’s see the result of our object when an employee goes on Long Term Disability:

StephanieBM01_10-1744765618321.png

Finally, for employees hired during the year (2024), the days prior to their hire are included in our absence count. Let's see the result of our object for an employee hired on July 1st, 2024:

StephanieBM01_11-1744765618349.png

There we go, challenge resolved! Now, we just need to load our import file again to update the values for all employees.

 

Solution: Version Expert!

I went back to Alex to present the intermediary version of the solution. Alex said, "This is great, Stéphanie! I could use this in compensation planning. But for 2025, can you make your object reflect live calculations as time passes?”. Truth be told, Alex did not push it there, but I thought it would have been a good follow-up question. I also wanted to implement this it because it would look better in my demo system 😊.

So, here it goes...

For the expert mode solution, we'll create two new fields for the year 2025 (the ongoing year at the time of writing this blog) on our custom objects.

  • We'll need to have IF conditions of the rule so that our absence count and our pro-rata are dynamic as time advances.
  • Additionally, we'll have IF conditions for when the year is finished and the counter become static.

Here is a look at our variables, what they do, and where we will use them in our rule:

StephanieBM01_12-1744765618377.png

 

And now, the rule itself! (It's starting to look a bit more complicated, but remember, we're in the Expert version of the solution!):

StephanieBM01_13-1744765618401.png

What's left is to trigger the rule automatically every day so that the counts and rates get updated as time passes in 2025!

To achieve this, we'll need to use a mix of Integrations in Integration Center and Intelligent Services. I won't go into the details of Integration Center and Intelligent Services here (this blog has already taken way longer to write than planned), but I like the setup with the following three integrations:

StephanieBM01_14-1744765618406.png

 

 

Absence Count – Intelligent Service - Hire

Trigger: Hire intelligent Service
Description: This integration will initialize / create the portlet for newly hired employees. Simply map the employee user ID to the external code of the custom portlet!
Note that if you are going-live with this solution you should to an upload of the custom object on all active employee prior to the go-live to initialize the portlet.

Absence Count – Intelligent Service – Time-Off

Trigger: Time-Off intelligent Service
Description: This integration will update the portlet whenever a time-off is saved in the system.

Absence Count – Schedule Daily Job

Trigger: Schedule daily job
Description: This integration will update the portlet daily, calculating days of absences and the presence rate as 2025 progresses.

Now, just ensure your intelligent services (hire and time-off) are set up to trigger the integrations mentioned above and schedule the third one. And there you go! The custom objects will reflect live data and get updated every day. Expert mode solution in a nutshell!

 

Conclusion

To finish…

First, the goal of this blog was to demonstrate how to make absence/presence pro-ratio data available in SuccessFactors for use in the Compensation Planning module. I presented three solutions to achieve this. I've developed these as proof of concepts and never had the chance to implement them. So, if you get to use this solution, please let me know. It will make me happy to know it was useful!

Second, many thanks to my friend, Alex Rodriguez, for bringing me these challenges every now and then!

Lastly, I just want to say that now I know how hard it is to keep it short when writing a blog about time 😉!

Cheers,

Stéphanie

3 Comments
xavierlegarrec
Product and Topic Expert
Product and Topic Expert

Hi @StephanieBM01 congrats on this great blog and thanks for sharing. I added it as a link on the "FTE and Proration examples" blog (link below). 

Regarding Maintenance of the MDF for a new cycle, would we recommend simply clearing existing entries in the non-recurring MDF then running IC jobs again ? 

For people looking for some information about integrating Time Off data with with Variable Pay (must be in eligibility rules) here is a blog that can help where I explain how to retrieve only the right records by creating a new field in Job Info with a business rule: 

xavierlegarrec_0-1744852330132.png

Merci !

Xavier

 

PetraRana
Participant
0 Kudos

Well written and very interesting blog! Thank you

StephanieBM01
Participant
0 Kudos

@xavierlegarrec I knew you would like that one! Thanks a lot for adding a reference to it in your own articles.

I don't have much of an opinion on the maintenance... but now that you are having me thinking about it... I like the idea the expert solution and adding new fields every year in the object. Not for Compensation purposes but more for having these fields available to be use in Stories and report on them. I am a EC consultant who does like reporting a lot after all 😛

Labels in this area