ce**********@gmail.com wrote:

Hi,.

I'm trying to make a inventory and average cost that includes receivied

weights and cost.

The cost changes everytime we receivie product as cost from vendor

changes every time.

Everyday I would get a average cost depending on a calculation..and the

tricky part will be getting the last day;'s received cost.

for example

DATE Weight Cost Average Cost

12/10/06 1000 3.13 3.13

12/11/06 1232 3.14 3.16

now to calculate next day's average cost I need to get 3.16

Why? The next day's average cost will be

Sum(Weight*Cost) / Sum(Weight)

for all three days. The average cost for the previous day is not

required.