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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
crln-blue
Post Patron
Post Patron

Running/Cumulative total is wrong, showing the base values

Hello! I'm a bit new to PowerBI and I know this gets asked a lot but I have a problem with my running/cumulative total. I've been trying to solve this for more than a week now but I still can't solve it.

 

I have a report with different measures in a hierarchy with date value and I'm computing my running total. But my running total is returning the base value which is not the right value.


Below is my running total measure:

 

SUMX(FILTER(ALLSELECTED('Cashflow A'[Date].[Month]),'Cashflow A'[Date].[Month] <= MAX('Cashflow A'[Date].[Month])),[Total Category AB])

 

My base value is [Total Category AB].

 

Below is the my visual:

crln-blue_0-1610939467645.png

 

I prepared a pbix file and replicated my calculations in order to share with you the issue. 

Github link (if the link above doesn't work)

 

Thank you very much in advance!

4 REPLIES 4
amitchandak
Super User
Super User

@crln-blue , Try like

SUMX(FILTER(ALLSELECTED('Cashflow A'[Date]),'Cashflow A'[Date] <= MAX('Cashflow A'[Date])),[Total Category AB])

or

SUMX(FILTER(ALLSELECTED('Cashflow A'),'Cashflow A'[Date] <= MAX('Cashflow A'[Date])),[Total Category AB])


@amitchandak wrote:

@crln-blue, Try like

SUMX(FILTER(ALLSELECTED('Cashflow A'[Date]),'Cashflow A'[Date] <= MAX('Cashflow A'[Date])),[Total Category AB])

or

SUMX(FILTER(ALLSELECTED('Cashflow A'),'Cashflow A'[Date] <= MAX('Cashflow A'[Date])),[Total Category AB])


I already tried this but it's still not working. The first formula you suggested gives off a large result and on the second formula, it's still the base value.

@crln-blue , I have done few changes. Added date table, modified formula for Total Category A , Total Category B, Create a measure(Cumulative)  etc.

 

Please check the file attached after signature.

Hello @amitchandak! Thanks for checking my powerbi file. I also checked the adjustments you did and I'm a bit confused why there is a separate table of dates. I think because of this, my other categories are not computed properly even though I already changed its logic. Also, I think the running total is not working because there is no value when used in the hierarchy. 

I checked the value (in a different way) of the running total and found out that it's still not working. Running total kept on getting the base value.

crln-blue_0-1610995546471.png

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.