Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Dynamic Cumulative Sum

Hi!

I´ve really searched all over the place and can´t find the answer to what I thought would be a simple business case:

 

I want to create a cumulative sum that accumulates depending on the sorting that is done by the user of the chart/table. There are four categories (A,B,C,D) and the user sorts the graph in ascending order by those categories. In that case I would like to my measure to contain;

- Category A = the total of category A

- Category B = the total of category A and B

- Category C = the total of category A, B and C

- Category D = the total of category A, B, C and D

 

But now the user sorts the graph in a different way, namely descending by category. Now I would like my measure to contain;

- Category D = the total of category D

- Category C = the total of category D and C

- Category B = the total of category D, C and B

- Category A = the total of category D, C, B and A

 

How can I achieve this? So far all solutions contain some kind of pre-defined ordering (line an index or rank or value). I just want to accumulate from left to right (in my graph) no matter the sorting that I use in my graph, using one measure. Any help would be greatly appreciated!

1 ACCEPTED SOLUTION
TomMartens
Super User
Super User

Hey,

 

unfortunately this is not possible.

This is due to the fact that a measure is not aware of the sorting of the axis in the visual.

 

For this reason, you might consider to provide a solution to your users that is build on bookmarks, where you use two different visuals where each is using a different measure.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

Hi, 

Did you find solution for your problem?  I am working on the similar situation, want my cummalitive value to be dynamic irrespective of way the value sort, the cummalitive value has to be in ascending order. Any help would be appreciated. 

Anonymous
Not applicable

Hi Shikha,

After I got the answer that it wasn´t possible I gave up on this subject so I´m sorry to say I can´t help you with this. Should you find the solution to this this problem I´m all ears!

Kind regards,

Guust

TomMartens
Super User
Super User

Hey,

 

unfortunately this is not possible.

This is due to the fact that a measure is not aware of the sorting of the axis in the visual.

 

For this reason, you might consider to provide a solution to your users that is build on bookmarks, where you use two different visuals where each is using a different measure.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany
Anonymous
Not applicable

Hi Tom,

For some reason I thought this would be possible, but your explanation makes sense.

Thanks a lot for your answer. I will will stop my quest for now 🙂

Kind regards,

Guust

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.