7 Replies Latest reply on Jan 5, 2017 7:34 PM by Walt Reed

    How to calculate business days between two dates in different years

    Emily Z

      Hi,

       

      I'm trying to calculate business days between 2 dates. My formula works when the 2 dates fall into the same year, but how to make it work when the 2 dates fall into different years? Pls. help. Thanks!

       

      DATEDIFF('weekday',[End Date],[Start Date]) - 2 * (DATEPART('week',[Start Date]) - DATEPART('week',[End Date])) + (IF DATENAME('weekday',[End Date]) = 'Sunday' THEN 1 ELSE 0 END) - SUM([No of holidays])

       

      Emily