Forum Discussion
thampton
Helper III
5 years agoRunning Total By Month on Date Table
Hello - I have seen many answers to this questions but none seem to work in my situation. I have a date table (date, day, month, etc) and a column showing business days. I would like to have a MTD bu...
- Anonymous5 years ago
Hi thampton ,
According to your description, I create this data from 2021.1.1-2021.2.28:
Here are the steps you can follow:
1. Create calculated table.
Business Day = var _weekday=WEEKDAY('Table'[date]) return IF(OR(_weekday=6,_weekday=7),0,1)running total = CALCULATE(SUM('Table'[Business Day]),FILTER('Table','Table'[Business Day]=1&&'Table'[Month]=EARLIER('Table'[Month])&&'Table'[date]<=TODAY()))2. Result.
You can downloaded PBIX file from here.Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
5 years agoNot applicable
Hi thampton ,
According to your description, I create this data from 2021.1.1-2021.2.28:
Here are the steps you can follow:
1. Create calculated table.
Business Day =
var _weekday=WEEKDAY('Table'[date])
return
IF(OR(_weekday=6,_weekday=7),0,1)running total =
CALCULATE(SUM('Table'[Business Day]),FILTER('Table','Table'[Business Day]=1&&'Table'[Month]=EARLIER('Table'[Month])&&'Table'[date]<=TODAY()))2. Result.
You can downloaded PBIX file from here.
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.