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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

how to calculate cumulative value from result of another calculation(divide)

Hi, I need to get  a cumulative column, the culumlative is based on result of another measure use divide:

here is the measure I created and the result:

cal_bur_total_ar_dor =
90*(DIVIDE(
    CALCULATE(SUM(tb[total_ar])),
    CALCULATE(SUM(tb[rev])))
cal_bur_acc_ar_dor =
CALCULATE(SUMX('tb',[cal_bur_total_ar_dor]),
FILTER(ALLSELECTED('tb'),
'tb'[busy_year_month]<=MAX('tb'[busy_year_month]))
)

cal_bur_total_ar_dor is the correct reslut that used for calculate cumulative value, while cal_bur_acc_ar_dor did not get the result needed

The cumulative measure need to be like this: 0, 16, 79, 160, 212...

do you have any ideas to correct the measure? Thank you.

1 ACCEPTED SOLUTION
HoangHugo
Solution Specialist
Solution Specialist

Hi, try this one

cal_bur_acc_ar_dor =
var year_month = SELECTEDVALUE(busy_year_month)
return
 SUMX(CALCULATABLE(SUMMARIZE(busy_year_month),REMOVEFILTER(busy_year_month),[busy_year_monht]<= year_month),cal_bur_total_ar_dor)

 

View solution in original post

2 REPLIES 2
HoangHugo
Solution Specialist
Solution Specialist

Hi, try this one

cal_bur_acc_ar_dor =
var year_month = SELECTEDVALUE(busy_year_month)
return
 SUMX(CALCULATABLE(SUMMARIZE(busy_year_month),REMOVEFILTER(busy_year_month),[busy_year_monht]<= year_month),cal_bur_total_ar_dor)

 

Anonymous
Not applicable

Thank you, solved

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

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