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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
sebastianharg
Frequent Visitor

Problem with cumulative column

Hello! I have a problem with this cumulative column, I dont know what im doing wrong, but the cumulative always show the result of  "total dolar" and not the cumulative as I want.

 

the measure "Loan Balance" is

Loan Balance = SUM(TANGODB2[Subtotal_Dolar])
 
thanks for the help!!

 

sebastianharg_0-1625151419210.png

 

1 ACCEPTED SOLUTION

Hi,  @sebastianharg 

If you are referring to the monthly cumulative calculation, please change your formula as follows:

 

Cumulative Loan Balance = 
CALCULATE (
    [Loan Balance],
    FILTER (
        ALL ( TANGODB2 ),
        ( TANGODB2[FECHA_EMIS].[Ano] = MAX ( TANGODB2[FECHA_EMIS].[Ano] ) )
            && (
                TANGODB2[FECHA_EMIS].[Mes] = MAX ( TANGODB2[FECHA_EMIS].[Mes] )
                    && ( TANGODB2[FECHA_EMIS] <= MAX ( TANGODB2[FECHA_EMIS] ) )
            )
    )
)

 

 

Best Regards,
Community Support Team _ Eason

View solution in original post

4 REPLIES 4
sebastianharg
Frequent Visitor

Any Ideas? thanks!

Hi,  @sebastianharg 

If you are referring to the monthly cumulative calculation, please change your formula as follows:

 

Cumulative Loan Balance = 
CALCULATE (
    [Loan Balance],
    FILTER (
        ALL ( TANGODB2 ),
        ( TANGODB2[FECHA_EMIS].[Ano] = MAX ( TANGODB2[FECHA_EMIS].[Ano] ) )
            && (
                TANGODB2[FECHA_EMIS].[Mes] = MAX ( TANGODB2[FECHA_EMIS].[Mes] )
                    && ( TANGODB2[FECHA_EMIS] <= MAX ( TANGODB2[FECHA_EMIS] ) )
            )
    )
)

 

 

Best Regards,
Community Support Team _ Eason

selimovd
Super User
Super User

Hey @sebastianharg ,

 

your problem is the filter context.

Each line can only see the date of the current line.

 

What date frame do you want to summarize? From the beginning of the year until the chosen date? From the beginning of the data until the chosen date?

 

If it's from the beginning of the year, then use the TOTALYTD function in the CALCULATE statement.

If it's from the beginning of all records, then use DATESINBETWEEN with FIRSTDATE(ALL(myDateTable[Date])) in the CALCULATE statement.

 

If you need any help please let me know.
If I answered your question I would be happy if you could mark my post as a solution ✔️ and give it a thumbs up 👍
 
Best regards
Denis
 

@selimovd  thanks for your help, i would like to cumulate something dinamic depending on the range of that I selected for example in this case, from the month of june , cumulative from 1st of june to 30 of june.

 

is this possible?

 

 

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.