Note: This was originally posted by an inactive account. Content was preserved by moving under an admin account.
Originally posted by: awilliams1024Hi Maria,
The dateAdjust() function does not take into consideration whether the adjustment period includes weekends so you would need to account for these days when determining the actual number of days to increment/decrement the start date by.
Here is one way you could do this. It is relatively fast for smaller adjustments/number of records. However, due to the iterative nature of the adjustment mechanism used, there may be better ways of achieving this if there is a large adjustment period and/or many input records.
Adjust_by_Workdays--share.brg
Btw, there is an in-built node that calculates the converse - the number of working days between two dates (i.e. equivalent of the Excel networkday() or networkday.intl() functions); this is the Calculate Workdays node in the Profiling and Patterns category.
Regards,
Adrian