Forum Discussion
puru85
2 years agoHelper II
Workday calculation
Hi Experts, I have requirement to calculate workday per month. The Logic for workday calculation is: Number of days per month minus public holidays, Saturdays, and Wednesdays. If a public hol...
- 2 years ago
Hi puru85
Modify the formula of column isworkday to :Not work day =IF('MasterCalendar'[Date] IN VALUES('Public Holiday'[Date]) && MasterCalendar[Weekday Number] =4,2,IF('MasterCalendar'[Date] IN VALUES('Public Holiday'[Date]) || MasterCalendar[Weekday Number] =7 || MasterCalendar[Weekday Number] =4,1,0))Result :
modified pbix is attachedIf this post helps, then please consider Accepting it as the solution to help the other members find it more quickly.
puru85
2 years agoHelper II
Hi Ritaf1983 mickey64 ryan_mayu ,
Thank you for helping me.
The measure you have created is calculating:
Number of days per month minus public holidays, Saturdays, and Wednesdays.
But requirement is:
Number of days per month minus public holidays, Saturdays, and Wednesdays. If a public holiday falls on a Wednesday, it should be additionally subtracted.
Please refer to below Master Calender Table for May 2024.
1 May and 22 May is Public Holiday which falls on Wednesday so it should be additionally subtracted.
So the number of working days for May 2024 will be: 20.