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
Thigs
Helper IV
Helper IV

Calculated Column Running Total

Hi all, 

I've looked at several other posts answering similar questions but can't find exactly what I need. Basically, I have a column for Index (starting at 1), and a column for quantity of items. I want to do a running total of the quantity based on the Index column - but it needs to be in a calculated column rather than a measure as I need to use the column itsself for an additional analysis in a bit. I have tried the following, but it doesn't work - 

 

Cumulative Total =
CALCULATE (
SUM('Data'[QtyPicked]),
FILTER (
ALL( 'Data'[Index] ),
'Data'[Index] <= MAX ( 'Data'[Index] )
)
)
 
It seems to just be giving me the quantity, not the running quantity
 
I also tried something like this - 
Running Total = if('Data'[Index] = 1, 'Data'[QtyPicked],
CALCULATE(sum('Data'[QtyPicked]),
FILTER( 'Data'[Index] <= MAX('Data'[Index]))))
 
Which also gave crazy numbers, so no good either. 
1 ACCEPTED SOLUTION
tamerj1
Super User
Super User

Hi @Thigs 

for a calculated column you can use 

Cumulative Total =
SUMX (
    FILTER ( 'Data', 'Data'[Index] <= EARLIER ( 'Data'[Index] ) ),
    'Data'[QtyPicked]
)

View solution in original post

1 REPLY 1
tamerj1
Super User
Super User

Hi @Thigs 

for a calculated column you can use 

Cumulative Total =
SUMX (
    FILTER ( 'Data', 'Data'[Index] <= EARLIER ( 'Data'[Index] ) ),
    'Data'[QtyPicked]
)

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!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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