Forum Discussion
Working Days based on start date
Is it possible to get an end date that is exactly 10 business days from the start date (excluding weekends and public holidays)?
Hi, hemendranath
You need a ‘Holiday Table’ that lists all your holiday so that you can add a calculated column to 'Calendar' Table to mark all your working days.
Workday = IF ( WEEKDAY ( 'Calendar'[Date], 2 ) IN { 1, 2, 3, 4, 5 } && NOT 'Calendar'[Date] IN VALUES ( 'Holiday Table'[Date] ), "Workday", "Weenkends/hoiliday" )Then, you can try the following formula to calculate the end date.
End Date = CALCULATE ( MAX( 'Calendar'[Date] ), FILTER ( 'Calendar', NETWORKDAYS ( MAX ( 'Table'[Date] ), 'Calendar'[Date], 1, VALUES ( 'Holiday Table'[Date] ) ) = 10 && 'Calendar'[Workday] = "Workday" ) )Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
1 Reply
- v-easonf-msftCommunity Support
Hi, hemendranath
You need a ‘Holiday Table’ that lists all your holiday so that you can add a calculated column to 'Calendar' Table to mark all your working days.
Workday = IF ( WEEKDAY ( 'Calendar'[Date], 2 ) IN { 1, 2, 3, 4, 5 } && NOT 'Calendar'[Date] IN VALUES ( 'Holiday Table'[Date] ), "Workday", "Weenkends/hoiliday" )Then, you can try the following formula to calculate the end date.
End Date = CALCULATE ( MAX( 'Calendar'[Date] ), FILTER ( 'Calendar', NETWORKDAYS ( MAX ( 'Table'[Date] ), 'Calendar'[Date], 1, VALUES ( 'Holiday Table'[Date] ) ) = 10 && 'Calendar'[Workday] = "Workday" ) )Best Regards,
Community Support Team _ Eason
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.