Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
I have found the following 4 ways to calculate a running total as a measure. What are the pros and cons of each method?
Solved! Go to Solution.
There isn't any difference between those methods, the performance speeds are logically the same since they all just comparing dates. Method 1 and Method 2 are the same, Method 1 just stores the MaxDate into a variable then use it in the return expression.
What's important is the different between using All(table) and Allselected(table). If you want to using filter or slicer on the the running total measure, you would need to using allselected() instead of just ALL(). For example:
Item Running Total2 =
CALCULATE(
SUM('Table'[Item]),
FILTER(
ALLSELECTED('Table'[Date]),
'Table'[Date] <= MAX('Table'[Date])))
There isn't any difference between those methods, the performance speeds are logically the same since they all just comparing dates. Method 1 and Method 2 are the same, Method 1 just stores the MaxDate into a variable then use it in the return expression.
What's important is the different between using All(table) and Allselected(table). If you want to using filter or slicer on the the running total measure, you would need to using allselected() instead of just ALL(). For example:
Item Running Total2 =
CALCULATE(
SUM('Table'[Item]),
FILTER(
ALLSELECTED('Table'[Date]),
'Table'[Date] <= MAX('Table'[Date])))
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.
User | Count |
---|---|
9 | |
8 | |
7 | |
4 | |
3 |
User | Count |
---|---|
15 | |
14 | |
12 | |
10 | |
9 |