Forum Discussion

Zarlot531's avatar
Zarlot531
Icon for Helper V rankHelper V
5 years ago
Solved

Having trouble getting a rolling sum to work properly

I have a dataset that provides "Starting RMR" (RMR is recurring monthly revenue) by year but then also shows the first cancellation by year. So in the pivot below I have RMR by start year going acros...
  • Zarlot531's avatar
    Zarlot531
    5 years ago

     

    In the Dax formula below/second image below you'll see *a* solution. Not sure if it's the best one. But there's another weird problem. The Pivot Table doesn't sum the row grand totals of the rolling measure properly, even though everything else is summed and rolls properly within the columns. See first image below. The row grand total takes only the latest in the row into of summing it. Hmm. 

     

    =calculate(sum([First Cancel RMR]),filter(allselected('Range'),Range[First Cancel Year]<=max([First Cancel Year]) && max(Range[StartYear]) = 'Range'[StartYear]))