Supplies are limited. Contact info@espc.tech right away to save your spot before the conference sells out.
Get your discountScore big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount
Hi guys,
I need to calculate a measure as days from first day of the month to RDD date excluding fridays and official holidays in this days range.
I have three tables
order scheduel that has the RDD
Official holidays that has Day, Month of official holidays
date table that has weekends column that marks fridays as true
How can I calculate the equation I mentioned at the top.
Any help please
I recommend you change your calendar table to include the holidays, and to flip your logic around. Instead of flagging the days off (weekend/holiday), flag the actual working days, ideally as 1 vs 0. That way your calculation can be done via SUMX directly. Not strictly required, but easier. If you want more pointers, please provide sample data in usable format and show the expected outcome.
I should add three days to today's date excluding weekends and official holidays and divide this by number of days in month excluding weekends and holidays
For example date today is 24-dec-2020 so after adding three days it should be 28-dec-2020 as 25-dec is weekend (Friday).
then get number of days from start of the month to 28-dec subtracting fridays(4) and holidays that should be 24 days.
User | Count |
---|---|
10 | |
5 | |
4 | |
4 | |
3 |
User | Count |
---|---|
14 | |
9 | |
5 | |
5 | |
4 |