So, I'm using Magmi's ingest functionality to run my own instance of Magmi to import product stocks.

I'm setting an array:

array("sku"=>$sku, "stock_id"=>$key, "qty"=>$qty)

Then ingesting that array. Inventory with positive numbers get imported just fine and updates the old number with the new number.

However, when the new number is negative, instead of setting the inventory amount to that negative number, Magmi subtracts the new inventory from the old inventory.

Example: old inventory is 5, new inventory is -3 and after ingesting the -3, the new inventory number is 2 (where it should just be set to -3).

This effect is cumulative. Ingesting the same negative multiple times keeps driving the negative inventory lower.


Magmi has a "magmi_qty_absolute" extra column to handle this.

if you set "magmi_qty_absolute" column value to 1 , then magmi would consider the negative stock as absolute instead of relative to current stock.

you may use the "Value Replacer" plugin to force this value for all your input data without changing your data source.

  • would please post your value replacer expression here – liyakat Feb 9 '15 at 10:52
  • 1
    to force this value to 1, simply set : - replaced attributes : magmi_qty_absolute - set value 1 in the value field for magmi_qty_absolute – dweeves Feb 13 '15 at 14:12

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.