Measure to "carry forward" a value to infinity

karenlp97

New Member
Joined
May 6, 2019
Messages
2
Overall Business Problem - graph value of unused inventory that is sitting on shelves

I have a Cal Column, "Running Total Highest Primkey Calc Column" that takes the value of the running total (column not shown) with the highest prikey for the month.

I need a measure that dynamically "carrying forward" this value for a particular Product/Material, even if there are no more rows in the dataset for that particular Product/Material.

The logic I believe I want is, for each Material:
- If next period does not have any records for that Material, carry forward previous period's ending total
-Else If the next period does have records for that Material, then take the value from the next period with the highest primary key for that Material

In my attached screenshot, I'm showing the current measure that does the "carry forward" bit, but I don't want it to sum, rather I need it to follow the logic above.

In attached screenshot, Oct in 2022 should be sum of Product A's value [11,502.54] + Product B's value from September [1080.27] = 12,582.81. This value should be carried forward "forever" since there are no more records for either Material.

I hope this made sense - I feel like the solution is out there and I have been looking at this for too long!



TIA
 

Attachments

  • Capture.JPG
    Capture.JPG
    182.8 KB · Views: 8

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.

Forum statistics

Threads
1,215,875
Messages
6,127,477
Members
449,385
Latest member
KMGLarson

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top