Example: Configure a Parental Leave Upper Limit
This example illustrates how to configure a series of nested calculations to calculate the
Time Off Plan Balance Upper Limit
value for a time off plan. This top-level arithmetic calculation (Parental Leave Upper Limit
) enables Workday to check how many children under the age of 4 a worker has, as of the period end date, and prevent the plan balance going above the annual limit of 5 days per child. You'll create 9 separate calculations that together feed into the final result for the top-level calculation, which you'll use later when configuring the time off plan:
Security:
- Set Up: Calculations - Genericdomain in the Core Payroll functional area.
- Set Up: Time OffandSet Up: Time Off (Calculations - Generic)domains in the Time Off and Leave functional area.
- Dependent Age at Period End DateCreate a calculation to determine the dependent's age at the period end date, using Workday-owned instance value calculations (IVCs) for the period start and end dates.
- Access theCreate Date Difference Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameDependent Age at Period End DateCategoryAbsenceIntervalYearStart DateDependent: Date of BirthEnd DatePeriod: Period End Date
- Dependent Age < 4 as of Period EndCreate a calculation to determine whether the dependent's age is less than 4 as of the period end date, using the result of the previous calculation.
- Access theCreate Value Comparison Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameDependent Age < 4 as of Period EndCategoryAbsence1st OperandDependent Age at Period End DateOperatorless than2nd Operand4
- Next Period Start DateCreate a calculation to determine the start of the next period using a Workday-owned IVC.
- Access theCreate Date Increment/Decrement Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameNext Period Start DateCategoryAbsenceStart DatePeriod: Period End DateDay1
- Dependent Date of Birth ExistsCreate a calculation to return the dependent's date of birth for the period, using the result of the previous calculation.
- Access theCreate Date Difference Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameDependent Date of Birth ExistsCategoryAbsenceIntervalDayStart DateDependent: Date of BirthEnd DateNext Period Start Date
- Dependent Date of Birth Exists in Period or Prior PeriodCreate a calculation to determine whether the dependent's date of birth exists in this or a prior period, using the result of the previous calculation.
- Access theCreate Value Comparison Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameDependent Date of Birth Exists in Period or Prior PeriodCategoryAbsence1st OperandDependent DOB ExistsOperatorgreater than2nd Operand0
- Dependent Age GTE 0 and < 4 as of Period End DateCreate a calculation to determine whether the dependent's age is greater than or equal to zero and less than 4 as of the period end date, using 2 of the previous calculation results as conditions.
- Access theCreate Logic Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameDependent Age GTE 0 and < 4 as of Period End DateCategoryAbsenceOperatorANDCalculationDependent Age < 4 as of Period EndDependent DOB Exists in Period or Prior Period
- CC Dependent Age < 4 as of Period End DateCreate a calculation to check that the dependent's age is under 4 as of the period end date, using the previous calculation as a condition, and returning a result if the condition is true.
- Access theCreate Conditional Calculationtask.
- Enter or select these values:FieldValueNameCC Dependent Age < 4 as of Period End DateCategoryAbsenceOrderaConditionDependent Age GTE 0 and < 4 as of Period End DateResult1Default Response0
- Number of Dependents Under Age 4 as of Period End DateCreate a calculation to determine the number of dependents under the age of 4 as of the end of the period by aggregating the result of the previous calculation.
- Access theCreate Aggregate Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameNumber of Dependents Under Age 4 as of Period End DateCategoryAbsenceFunctionSumOperandCC Dependent Age < 4 as of Period End DateInstances for Operand CalculationDependents
- Parental Leave Upper LimitYou can now create the top-level calculation for theTime Off Plan Balance Upper Limitvalue using the previous calculation that ties all of the results together.
- Access theCreate Arithmetic Calculationtask.
- Enter or select these values and clickOKandDone.FieldValueNameParental Leave Upper LimitCategoryAbsence1st OperandNumber of Dependents Under Age of 4 as of Period End DateOperatorMultiply2nd Operand5