Symptom
- The function Get Number of Calendar Days() throws an error if start date is greater than end date.
Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.
Environment
SAP SuccessFactors Employee Central - Time Off
Reproducing the Issue
Cause
- Before b1911 release, there existed no validation to check if the start date entered in the function is on or before the end date entered in the function, which lead to unexpected results as the rule function was not designed to be called with a wrong order.
- Hence Engineering enhanced the behavior by adding a data validation message.
Resolution
- The function will throw a validation error when start date > end date during rule execution.
- The existing rules will need to be modified to accomodate this validation, if there is a possibility of rule function having start date > end date. E.g. Before using the function in a set statement, please add an if condition to check if start date to be entered in the function is on or before the end date. Example Screenshot:
Keywords
Get Number of Calendar Days, getCalendarDays, Validation, TIM-10774, Time Off, Business Rules, Employee Central Error happen when invoke rule function The start date is after end date , KBA , LOD-SF-EC-TIM , Time Off , Problem
Product
SAP SuccessFactors Employee Central 1911 ; SAP SuccessFactors HXM Core 1911