Hello,
I have a formula that was created over a year ago that is supposed to do the following:
- Calculate the number of business days between two dates
- If Actual is before Scheduled then it’s a negative number, but if it’s after then it’s a positive number
The formula seems to be working for calculating days, but not business days, and I can’t remember how I put this formula together, so I don’t know how to tweak it (facepalm). I put formulas together with help from Google, forums, and praying lol, it doesn't come natural to me, so I really appreciate the help.
Formula:
dateBetween(end(prop("Actual Published Date")), start(prop("Scheduled Publish Date")), "days") - 1 - (dateBetween(end(prop("Actual Published Date")), start(prop("Scheduled Publish Date")), "weeks") * 2 + min(max(day(prop("Scheduled Publish Date")) + dateBetween(end(prop("Actual Published Date")), start(prop("Scheduled Publish Date")), "days") % 7 - 5, 0), 2)) - 1