Forum Discussion

pierredelareux's avatar
9 years ago

Cumulative Total

Hi,

 

I know this topic has been treated but I have a special request.

Thanks to article I found the way to get the cumulative total as a mesure like below :

 

Budget Corrigé Cumulé =
VAR CurIndex = MAX('S-Curve'[Index])
RETURN
CALCULATE(SUM('S-Curve'[Budget Corrige]);FILTER(ALL('S-Curve');'S-Curve'[Index]<=CurIndex))

 

There is another colum in is tab : PHASE.

Whe n I select a PHASE value the cumative total is false.

 

I've tried to filter by PHASE but it doesn't help.

 

Thanks

12 Replies

  • Hey,

     

    you should sightly rearrange your model a little and add an additional table "Index". This table then takes the roll of the date table.

     

    Please have a closer look here: http://www.daxpatterns.com/cumulative-total/

     

    You are using ALL(table) in your calculation, that "overrules" the filter from the phase column, maybe you should also consider to create a phase table, then you're model takes the form of a star schema (dimension tables and fact tables).

     

    From my experience a lot of of calculations become difficult or even impossible, if there is just one table.

     

    Hope this helps

    Tom