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

To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.

Reply
Antmkjr
Post Patron
Post Patron

Cumulative over cumulative performance

https://drive.google.com/file/d/1GznvuGASdWCxpaIl3MAjtnMoJmmj6HPB/view?usp=sharing

 

In the file attached, the formula for Cumulative Final To Collect Result is working fine, but in the actual model the performance is very bad. Any ways to improve ?

 

Cumulative Final To Collect Result =
CALCULATE( [Cumulative Final To Collect Prep],
FILTER( ALLSELECTED('Date'),
'Date'[Date] <= MAX( 'Date'[Date] )
)
)

 

Cumulative Final To Collect Prep =
VAR vTable =
ADDCOLUMNS(
SUMMARIZE( 'Date', 'Date'[Year], 'Date'[MonthName] ),
"@Total",
[Final To Collect]+[Total Project Collections]
)
RETURN

SUMX( vTable, [@Total] )
 
 
 

AnuTomy_0-1609329336352.png

 

2 REPLIES 2
PaulPalma
Frequent Visitor

@Antmkjr 

 

I recommend reviewing this resource: Cumulative total – DAX Patterns

 

Based on your example I believe the main performance issue is related to iterations. You are creating a variable table in your DAX expression to create a Date Table for iterations. I recommend to use the power of the relationships with the Data Table to drive your DAX computations.

 

Example "Cumulative Final To Collect Prep" can most likely reduced to 

 

Cumulative Final To Collect Prep =

[Final To Collect]+[Total Project Collections]

 

All the best,

 

Paul

lbendlin
Super User
Super User

What are the filters that influence the result of the computation? Could you get away with using a calculated column instead of a measure? At least for part of the formula?

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.