Number of working days using a date field to get that months working day

CASE  WHEN {date} IS NOT NULL THEN    TO_NUMBER(TO_CHAR(LAST_DAY({date}), ‘DD’)) –  (FLOOR(    (      (TO_NUMBER(TO_CHAR(LAST_DAY({date}), ‘DD’)) + ( TO_NUMBER(TO_CHAR(TO_DATE(TO_CHAR({date}, ‘YYYY-MM’) || ‘-01’, ‘YYYY-MM-DD’),’DD’)) -1) ) / 7       )  ) * 2)  ELSE 0 END  

Leave a comment

Your email address will not be published. Required fields are marked *