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
Antmkjr
Helper V
Helper V

Cumulative Balance Issue

I want the Cumulative Balance Updated column to be the cumulative of Balance Current Month Updated

 
 

snip.PNG

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

The below formula is not working:

VAR Result_in =
Total
+ IF (
Total < 0,
Total * -1
)
RETURN
CALCULATE (
Result_in,
FILTER ( ALLSELECTED( ( ‘Date’ )), ‘Date’[Date] <= MAX ( ‘Date’[Date] ) )
)

 

 

Also the below is not working

Cumulative Balance Updated =
CALCULATE (
[Balance Current Month Updated],
FILTER ( ALLSELECTED( ( ‘Date’ )), ‘Date’[Date] <= MAX ( ‘Date’[Date] ) )
)

 

Link to pbix:

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

1 ACCEPTED SOLUTION

@Antmkjr , I think across tables data is not getting added up in the context so forced that in suggested formula

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@Antmkjr , Try like

Cumulative Balance Updated = 
VAR Result =
     CALCULATE (
            sumx(SUMMARIZE('Date','Date'[MonthnYear],"_1",[Balance Current Month Updated]),[_1]),
            FILTER ( ALLSELECTED ( 'Date' ), 'Date'[Date] <= MAX('Date'[Date] )
            ))
    
RETURN
    Result

Thanks, that works ! But why was my formula not working?

@Antmkjr , I think across tables data is not getting added up in the context so forced that in suggested formula

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.

Top Solution Authors