Forum Discussion
Anton0315
2 years agoFrequent Visitor
Calculate running total and reset it
Hello guys, I have made a running total that sums up every month, but I also want it to be able to restart the running total from the next month if it reaches a certain value (100), but it doesn't ...
danextian
Super User
2 years agoHi Anton0315
Consider integrating OFFSET into one of your measures. I have attached a sample pbix file to assist you in getting started. In this example, the cumulative count resets whenever there is a blank.
Anton0315
2 years agoFrequent Visitor
Hello,
It is not what I want because i don't have null values.
Look at this pbix file:
I want after it reaches 3000 (the red line to reset the cumalative sum), as you see it should be reseting in August but it is just summing the rest of the amounts it is not cumalative sum.
This is the meassure which I'm using
Var CumaltiveSUM = CALCULATE(sum(data[Private KM]), 'Calendar 6'[Date] <= max('Calendar 6'[Date]))
RETURN
IF(Cumaltivesum>=3000, CALCULATE(SUM(data[Private KM])), CumaltiveSUM),
I think there is a problem in the IF statment i have tried to do it alone but I can't.
Thank you in advance
I think there is a problem in the IF statment i have tried to do it alone but I can't.
Thank you in advance