Calculate date
Calculates date by adding or subtracting from a date.
Common use cases
- Data manipulation
Category
- Date & Time
Inputs (what you have)
| NAME | DESCRIPTION | TYPE | REQUIRED | EXAMPLE |
|---|---|---|---|---|
| Reference date | The date on which the calculation is based | Date | Yes | 2022-05-25 |
| Operation | The operation to be performed to the reference date.Note: At least one optional input should be enteredAccepted values:AddSubtract | PredefinedChoice List | Yes | Add |
| Inclusion | Choose whether to include or exclude weekends from the calculation.Accepted values:Exclude weekendsInclude weekends | PredefinedChoice List | Yes | Include weekends |
| Years | Years to be added or subtracted from reference date | Integer | No | 2 |
| Months | Months to be added or subtracted from reference date | Integer | No | 3 |
| Weeks | Weeks to be added or subtracted from reference date | Integer | No | 1 |
| Days | Days to be added or subtracted from reference date | Integer | No | 1 |
Note: the value of inputs can either be a set value in the configuration of the Wrk Action within the Wrkflow, or a variable from the Data Library. These variables in the Data Library section are the outputs of previous Wrk Actions in the Wrkflow.
Outputs (what you get)
| NAME | DESCRIPTION | TYPE | REQUIRED | EXAMPLE |
|---|---|---|---|---|
| Result weekday | The result weekday based on calculation | Text | Yes | Monday |
| Result date | The result date based on calculation | Date | Yes | 2024-08-26 |
Outcomes
| NAME | DESCRIPTION |
|---|---|
| Success | This status is selected if the date was correctly calculated. |
| Unsuccessful | This status is selected in the event of the following scenarios:- The instructions cannot be followed- All optional inputs were left blank |
Requirements
- N/A
How it works
- Reference date: January 13, 2022, Days: 6, the result weekday is Wednesday and calculated date is 19-Jan-2022.
- Reference date: January 13, 2022, Days: 6, Inclusion: Exclude weekends, the result weekday is Friday and calculated date is 21-Jan-2022.