Forum Discussion
adsam
2 years agoFrequent Visitor
Cumulative total with condition
Hi, I m trying to get cumulative total of "Forecast Gross" once "Closing stock" end e.g. Last Closing stock date is 18/03/24 so Forecast should start cumulating from 18/03, I was able to calcula...
- 2 years ago
Hi adsam,
Try to update your measure like this :
Demand Cumulative:= VAR LastClosingStk = CALCULATE(MAX([Transaction Date]),'Date'[DateWithSales] = TRUE,ALL('Date')) VAR CurrentDate = MAX('Date'[Date]) RETURN CALCULATE( [Forecast Gross], FILTER( ALL('Date'), 'Date'[Date] <= CurrentDate && 'Date'[Date] >= LastClosingStk ) )
adsam
2 years agoFrequent Visitor
Thanks it worked