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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Anonymous
Not applicable

Help with What-if Parameter

Situation

I am trying to use a What-if parameter to shrink inventory by a certain percentage each month. This is so we can account for things like breakage or lost inventory. I have the parameter working, whereby it will apply a selected percentage and decrease the inventory, but it is seemingly does it uniformly across all months.

 

What I need:

 

I need this parameter to compound. Meaning, I need to reduce January inventory by .1% and then I need that take that new inventory number and use it as the inventory for February and reduce it by .1% for March, and so on throughout the year. Is there a way to make this compound in this way?

 

Here is the parameter currently:

 

 

Inventory With Variable Shrink Adjustment = CALCULATE(SUM('2019_Inventory and LE'[Actual and LE])) - CALCULATE(SUM('2019_Inventory and LE'[Actual and LE])) * CALCULATE(SUM(Shrink[Shrink]))

 

 

 

Thanks!

 

1 ACCEPTED SOLUTION
TomMartens
Super User
Super User

Hey,

 

please allow me to point you to this blog post

https://www.minceddata.info/2018/02/21/using-table-iterators-to-calculate-a-future-value/

 

Even if this is about calculating a gain, but this of course this can also be interpreted as a growing deduction.

This blog considers some additional twists, but I guess the present solution can be adapted to your needs.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

1 REPLY 1
TomMartens
Super User
Super User

Hey,

 

please allow me to point you to this blog post

https://www.minceddata.info/2018/02/21/using-table-iterators-to-calculate-a-future-value/

 

Even if this is about calculating a gain, but this of course this can also be interpreted as a growing deduction.

This blog considers some additional twists, but I guess the present solution can be adapted to your needs.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.