# Average cost when QOH is zero or negative

Average cost is determined by

New Avg Cost = ( (Old AvgCost x prior QOH) + (new AvgCost x Qty being added) ) / (prior QOH + Added Qty)

Say the following happens…

1. A new Mfg’d part is created (Cost Type: Avg) . It’s costs’ (Avg, Last and Std) are 0.00.
2. A job is created to make said part, (Qty =1, for Stock)
3. Material issued to Job.
4. Part is shipped from stock, prior to being received into stock. (QOH = -1, Cost = 0)
5. The part is received into stock (QOH = 0, Cost= costs from Job)

Step 5 creates a ADJ-CST transaction, based on:

(0 x -1) + (123.45 x 1) / (-1 + 1)

But what about that zero in the divisor? Does the system check for that, and if it is zero, just assume there is nothing to do?

Why doesn’t the Last Cost at least get updated to the job cost?

And what if the QOH is negative, does that result in a negative average cost?

Hello Calvin,

I think I understand your question as what you are talking about unfortunately happens all the time. The part was shipped at the old value of zero, so you have a wash on the shipment, which will make the invoice look like it was 100% profit.

When you receive it off the job, then it updates the average cost in the part cost table, creates a debit to inventory and credit to WIP to clear out the job. So the net result is your inventory value will be out of balance since you shipped a zero value part before it was received and now you have a debit balance in Inventory with no quantity to match it.

The last part of your question is yes, if a part has a negative balance, it will value it based on the current average (or any) cost. I am surprised the last cost was not updated when you recieved the inventory from the job. Not sure why that would have happened.

Thanks,
John Gillenwater