Human Capital Management Blogs by SAP
Get insider info on SAP SuccessFactors HCM suite for core HR and payroll, time and attendance, talent management, employee experience management, and more in this SAP blog.
cancel
Showing results for 
Search instead for 
Did you mean: 
NeeleshKamath
Product and Topic Expert
Product and Topic Expert

Most of the customers have a common requirement to send alerts on employee’s service anniversary date. You could find various ways of achieving this using custom MDF, custom Jobs like Integration center, Custom Integration using HCI, etc.

In the below blog, I am going to demonstrate an approach which is not only simple and effective but does not need any custom MDF or custom process saving customer’s implementation time and cost. This approach makes use of standard EC objects and EC Jobs.

The blog makes use of following process

    • EC Employment Details Standard Object

 

    • Bizx Off Cycle Event Batch Job

 

    • EC Alerts and Notifications Framework



Important Note: Please don't create a support ticket in our queue, if you are modifying or changing the below best practice config. If you are modifying the rules, we cannot support your issues since this would be done by someone else and we are not sure what was the intention behind those changes

Without wasting much time, lets get started on the process

 

EC Employment Details Standard Object


In standard EC employment details add a new custom field named “ Number of Years” of type Long

Bizx Off Cycle Event Batch Job


Go to manage data and create new Off Cycle Event Batch as shown below



    • Create a new Associated Rule to calculate number of years:





    • Select Base object as Employment Details

 

    • Off Cycle event batch user group: Create a new group if not already there. To create new go to admin center and search “Manage Off Cycle Event Batch Groups” .Sample Group is shown below





    • Select filters as shown above for each anniversary year. Hire Date equal to offset 1 year, 2 years, 3 years and so on

 

    • Set Frequency as Daily



This concludes creating off cycle batch

EC Alerts and Notifications Framework


Create an Alert Message for each year of anniversary. You can create one and use copy paste and mass import using MDF import and export. For simplicity case, I have created for two years of anniversary





Create an alert workflow to be sent to the employee



Create a new rule to send alerts and attach it to employment details



Testing


Neelesh Ben2 is an employee who was hired on 15th Sep 2018 and today is 15th Sep 2019. He has completed 1 year of service.



The sequence of jobs to be run in provisioning is very important. First, we need to run Bizx off cycle event processing Job and then EC alerts and notification Job. Make sure even if you are scheduling them daily, please schedule them in this order only.

First, run the Off cycle job



Please Note Very Important Alert: Bizx Daily Rules batch now is not available in provisioning from 2311. It has to be scheduled from "Scheduled Job Manager" From SuccessFactors Instance(i.e from Admin Center UI)

After this job, the employment details object is modified with the number of years



Now run the EC alerts and notification job on the same day (This would run automatically if scheduled )



You can now check the inbox and alerts would be created



As you can see from above, we are able to achieve this with a simple process by just using EC Objects. There is no additional complexity of Custom MDFs and custom Integration Jobs considering there is an initial limit on 25 MDF objects. This is also performance efficient since it picks up and updates only those employees who have their anniversary on that particular day instead of  analyzing all the users.

Some Important Points

Many partners have tried this solution as of 2024 today and have been successful. But I have also received feedback from few partners that in some cases that the alerts are not processed for few users.  I am jotting some tips and ways to fix them . If you follow the below points, it will work for all cases. Please note it is not applicable to all. For most of them the standard solution still works. 

Reasons of rule not matching can be one of the below :

  • Multiple jobs scheduled and it failed causing inconsistent results. Please delete the Job which was scheduled second time . Only one job for EC alerts has to be scheduled
  • Please always check the log of EC Alerts and Notification Job from provisioning. It will give you an idea if the alert was triggered or not.
  • In Some Cases, I see that no alerts were sent since the rule did not match any conditions. The job was scheduled at 00:00 Midnight. This is a bit unpredictable since the Today() function used in alert rule may not fetch todays date but rather previous day’s date as the server date and today() could vary depending on DC your instance is. Hence Please try scheduling both off cycle and ec alert jobs during mid day i.e 12 PM afternoon onwards. This would ensure both server date and today() can be the same date always
  • OR if you don’t want to schedule the EC alert jobs later and want to have it at 00:00 you need to add one more or condition for alert rule to match the condition where Today() is still referring to previous day and not the exact anniversary date. For those cases this OR condition can be added as shown below

        

NeeleshKamath_0-1711081745909.png

This would ensure that where if the job is run at midnight and one of these conditions are met at job run at midnight i.e either today() is anniversary day or a day previous to it, the alert will be sent. This is a more safer option and alert rules not matching cases should not take place



I would request you to check the above and if you have any ideas to improve this blog further, please provide your valuable comments.

And also please do not forget to hit the Like button (only if you liked it ?)

 

54 Comments