Important: This article applies to the specific versions of software: X-Cart 5.2.13 and higher.


The add-on Update inventory for X-Cart provides a quick and easy way to update product quantities by importing a simple CSV file. This add-on works for both regular products and product variants.


Starting from X-Cart version 5.2.13, X-Cart has a full-featured import mode aimed at updating the existing items, which allows you to modify your product information (including the stock quantity, price and other product properties) using the standard X-Cart’s Import feature that can be used instead of the add-on "Update inventory".


The required CSV file format for importing product quantity information using the add-on Update inventory is as follows:

As you can see, the CSV file has just two fields:

Field in CSV file

What this field describes

Value type

sku

Unique identifier of the product or variant

String, Max. length: 32

qty

Stock level, unsigned positive number if the change is absolute and signed if the change is relative

Integer


(X-Cart 5.3.3+) When using qty field, you can also specify changes based on the current stock. Relative change is marked with the sign character, e.g. +5 (stock increase by 5 items) or -10 (stock decrease by 10 items).


In a store with the add-on Update inventory installed and enabled, the CSV file for updating product quantities can be imported via the Update quantity section (Catalog > Update quantity):

When importing a CSV file to update product quantities, the following rules apply:

  • If a SKU from the CSV file does not match the SKU of any existing product or (when using the add-on Product Variants) product variant in the store’s database, the error is logged, and the respective line in the CSV file is skipped.

  • Product quantities must be positive numbers. If a product quantity in the qty field is specified in the wrong format, the error is logged, and the respective line in the CSV file is skipped.

  • Any errors generated in the process of importing the CSV file with SKUs and quantities are displayed after the import process has been completed.

Related pages:

Did this answer your question?