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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
PersephoneK
New Member

Cumulative sum has strange behavior on table with other columns

Hello, I just created a "cumulative total" column and it works fine when I add it to a table with just the dates and the original total values (by date). But when I add another column that is a completely different metric, the cumulative metric gives the same value as the original total value.  See screenshots below of the two versions of the table (with and without the extra column (Total Time).  I have one page level filter applied in the filter pane, and a Year filter applied for the page (top corner slicer). 

 

This is the formula for my Cumulative total: 

Distance Cumulative = CALCULATE(Data_Master[Distance Total], FILTER( ALLSELECTED( Data_Master[Date] ) , 'Data_Master'[Date] <= MAX('Data_Master'[Date] )))

 

 

PersephoneK_0-1647965784883.png

Any help would be appreciated! Thank you!

1 ACCEPTED SOLUTION
johnt75
Super User
Super User

I think that the Time is being added to the filter context, try removing that filter like

Distance Cumulative = CALCULATE(Data_Master[Distance Total], REMOVEFILTERS(Data_Master[Time in hours]), ALLSELECTED( Data_Master[Date] ) , 'Data_Master'[Date] <= MAX('Data_Master'[Date] ))

View solution in original post

2 REPLIES 2
johnt75
Super User
Super User

I think that the Time is being added to the filter context, try removing that filter like

Distance Cumulative = CALCULATE(Data_Master[Distance Total], REMOVEFILTERS(Data_Master[Time in hours]), ALLSELECTED( Data_Master[Date] ) , 'Data_Master'[Date] <= MAX('Data_Master'[Date] ))

That worked brilliantly! Thank you!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors