DAX based on previous calculation

pociners

New Member
Joined
Mar 19, 2014
Messages
32
Hello everybody,

I want to calculate the future stock based on the incoming stock and forecast sales.
The data and calculation for the future stock is very simple actually, but i don't know how to manage it via power pivot or DAX, can you help me? please..

This is the data:
ColumnDataW0W1W2W3W4W5W6
A1Forecast100100100150100100
A2Incoming Stock2000200300300
A3Future Stock0100010000200
A4Future Stock Formula0=IF(
A3(W0)+A2(W1)-A1(W1)<0
,0
,A3(W0)+A2(W1)-A1(W1))
=IF(
A3(W1)+A2(W2)-A1(W2)<0
,0
,A3(W1)+A2(W2)-A1(W2))
=IF(
A3(W2)+A2(W3)-A1(W3)<0
,0
,A3(W2)+A2(W3)-A1(W3))

<tbody>
</tbody>

The A3 column is the result from A4 column. I assume that A3(W0) is zero.
Well, the formula for Future Stock is like looping from the previous. Can powerpivot manage this? or do you have any idea to solve this case?

If you have any question about my case, please feel free to ask.

Thanks,
Budy
 
Last edited:

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off

Forum statistics

Threads
1,216,102
Messages
6,128,846
Members
449,471
Latest member
lachbee

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