Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I calculate the Remainder:
Solved! Go to Solution.
Hm, I'm unfortunately stumped at the moment after looking at it for a while. The closest I got was using a cumulative total and the quotient in the PI measure, which at least solves your issue running total not resetting if the remainder was non-zero. However, that doesn't quite work with your requirement that the running total resets.
PI =
VAR CumulativeTotal =
CALCULATE (
SUM ( Epic[TeamsPi Avg] ),
REMOVEFILTERS ( Epic ),
Epic[Epic ID] <= SELECTEDVALUE ( Epic[Epic ID] )
)
VAR Divisor = SELECTEDVALUE ( Epic[Portfolio Supply] )
VAR Suffix = IF ( Divisor <> 0, QUOTIENT ( CumulativeTotal - 1, Divisor ) )
VAR Result = "PI " & FORMAT ( Suffix + 1, "0" )
RETURN IF ( ISINSCOPE ( Epic[Epic ID] ), Result ) -- gets rid of the nonsensical Total valueAccounting for the reset the first time it's with a non-zero remainder is easy; keeping that "memory" has proved more difficult for me, since you can only use one "formula" for the entire "column".
I wish I could be of more help at the moment but the above is the best I have for now. If I figure something else out, I'll let you know. 😄
Proud to be a Super User! | |
Hello,
Can you please share your pbix file?
Proud to be a Super User! | |
How do i attach my PBIX to this post? I looked at all the buttons and don't see an attach file or pbix. I see attach media, link pic, etc., but none to upload the PBIX.
You can upload it somewhere (ex: Google drive or Dropbox) and share the link to the file.
Proud to be a Super User! | |
Hm, I'm unfortunately stumped at the moment after looking at it for a while. The closest I got was using a cumulative total and the quotient in the PI measure, which at least solves your issue running total not resetting if the remainder was non-zero. However, that doesn't quite work with your requirement that the running total resets.
PI =
VAR CumulativeTotal =
CALCULATE (
SUM ( Epic[TeamsPi Avg] ),
REMOVEFILTERS ( Epic ),
Epic[Epic ID] <= SELECTEDVALUE ( Epic[Epic ID] )
)
VAR Divisor = SELECTEDVALUE ( Epic[Portfolio Supply] )
VAR Suffix = IF ( Divisor <> 0, QUOTIENT ( CumulativeTotal - 1, Divisor ) )
VAR Result = "PI " & FORMAT ( Suffix + 1, "0" )
RETURN IF ( ISINSCOPE ( Epic[Epic ID] ), Result ) -- gets rid of the nonsensical Total valueAccounting for the reset the first time it's with a non-zero remainder is easy; keeping that "memory" has proved more difficult for me, since you can only use one "formula" for the entire "column".
I wish I could be of more help at the moment but the above is the best I have for now. If I figure something else out, I'll let you know. 😄
Proud to be a Super User! | |
I appreciate you trying! If you can think of anything let me know. I'm still thinking and maybe need to redo the logic altogether.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 4 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 25 | |
| 17 | |
| 8 | |
| 8 | |
| 7 |