Forum Discussion

androo's avatar
androo
Icon for Advocate III rankAdvocate III
3 years ago
Solved

Conditional cumulative sum as new calculated column in datamodel

In the table below my desired result is the final column (it looks horrid here but pastes nicely enough into Excel). Index:Reference:PrevRowRef:Amount:Cumulative Amount:Desired Cumulative Result: ...
  • ryan_mayu's avatar
    3 years ago

    androo 

    is this what you want?

    Column = sumx(FILTER('Table','Table'[Reference]=EARLIER('Table'[Reference])&&'Table'[Index]<=EARLIER('Table'[Index])),'Table'[Amount])+0

     

    pls see the attachment below