6. Import Products


This Wizard will help you to update your database by selecting an appropriate action.

Pay attention to each page of the Wizard, when you import products to Zen Cart. Import is a rather complicated procedure and it may be destructive if performed incorrectly. Create Database backup before importing products especially if you do it for the first time.

To import products to Zen Cart follow a few steps listed below:

  1. First of all, prepare a .csv file for Import. Make sure it contains all the necessary fields and that all the data you are going to import are listed in the table. Here's a list of fields that your .csv file may include and detailed description of those fields:

Product ID - this is internal database field, it should be of numeric type only and must have unique values across the entire table. The value from .csv file will not be imported from the file or changed at your store as it should be assigned automatically by shopping cart itself (other database tables can have references to this field, pointing to specific products). During the Zen Cart import ID can be used for identifying products only. Check more about product identification below (step 6).

Model (SKU) - is a standard, alphanumeric string that uniquely identifies the product. It is assigned to the product by manufacturer according to the procedure and is used internationally. You should be able to receive the standard code for all your products from your supplier easily. Just contact them with this request. This field should have unique values and may be used for identifying products during the Zen Cart import, see step 6 for more about product identification.

In Stock - this field acquires "0" or "1" value only. It states availability of the product. For example, value "1" means that product is available in stock. In case it has "0" value than the product is not available for purchasing and will not be displayed at your Store. In case you skip this column, your products will be set as out of stock and will not be shown at frontend of your store. To set the value as "in stock" for all products you can specify 1 value for the first product in your .csv file and spread it for all products.

Price - the product price should be the cost of the product before tax or shipping. Do not include any rebates, coupons, or bulk discounts. Prices should be whole numbers with a maximum of two decimal places. Price fields are numeric; no text is permitted - do not include “$” or any other symbols.

Category - specify the category your product belongs to. If the product should be imported into subcategory use pipe character "|" to separate parent and sub category, for example: "Computers|Keyboards", the product will be assigned to Keyboards category. In case you have categories in separate column, please merge them in Excel using the following formula:

      1. =B2&"|"&C2
        1. where
        2. | - is category delimiter
        3. B2 - is your parent category column in .csv file and
        4. C2 - is sub category column in .csv file.

If you need to assign the same product to multiple categories, use double delimiter, like this one: "Computers|Keyboards||Computers|Other" in your .csv file. In this case, product will be assigned both to Keyboards sub category and to Other subcategory while import. In our case Pipe is used as category delimiter. Category delimiter character should be specified on the 5-th step. It is used to separate category names and specify full category tree path for given category. Category path is very similar to directory path, used to specify full file name in Windows, where every directory separated by backslash (\) character like shown in the following example - C:\Program Files\eMagicOne\Store Manager for Zen Cart\.

Product image - allows you to import images for the product. You can choose where you would like to upload pictures from - your local computer (in this case you need to have only image names in your .csv file like product_image_1.jpg) or external web URLs (in case you have image URLs from your supplier like http://supplierstore.com/bulkimages/image.jpg). Please note that in order to import images you have to set-up a proper FTP connection. Please check these articles how to upload images from local pc and how to upload images if you have external image URLs if you need help.

Attributes - Store Manager requires a specific formatting for product attributes. You are welcome to export a few products with attributes and you'll see the format. Also you can see an example below. Please note that you can use Excel to merge your attributes in case you have them in separate columns. You're welcome to contact your administrator for help or contact us and we'll provide you with the formula for additional fee.

Also you can import attributes from separate columns of .csv file. Please, note that it is convenient to use if you are updating products from supplier .csv file. In case you are importing products from one store to another one, you can use default system of Zen Cart attributes import, where attributes specified for each products in separate row, not in columns.

If you cannot download the file, see the one attached at the bottom of the page.

If your vendor provides you product list in Excel, you can convert your Excel files to the CSV format within the Microsoft Excel or OpenOffice application by using the Save As option. To do this you need to use File -> Save As dialog box which contains a list of alternative file formats. Among the file extensions offered, you can find Text CSV file format. By saving your file into CSV format, Microsoft Excel or OpenOffice will export the first active worksheet with the correct delimiters.

2. To start Zen Cart Import Products procedure you need to click on button which starts the Import/Export Wizard (please note that Products Import/Export Wizard is similar to Categories Import/Export Wizard).

Import/Export Products

3. Select "Import" in the Import/Export Wizard and click "Next >" button to continue.

Weclome import page

Store Manager for ZenCart provides an opportunity to import data from files of different formats, such as: csv, xml, xls, xlsx, ods, txt.

Browse button

4. Enter the .csv file you need to import or use browse button to select one.

Also you can Save Import Settings for future import of Zen Cart products or load one to use now.

5. Source file preview shows a part of .csv file, which is selected for import. There are no options to set, but you should pay some attention to field delimiter and quote character options, if some are used.

If you carefully check the very first line of the example, you'll notice that some words enclosed in quotes (") and are separated by semicolon (;) symbol. That are two important options you have to pay attention to - you will have to setup these settings on next page. Usually it is enough to see the first line, no need to investigate the entire file.

Also you can enable and set the row # you want to start Zen Cart import from.

6. Select fields delimiter and quote character page contains some important settings. If you specify wrong values, Zen Cart import may not work.

    1. Delimiter character is the delimiter that is used to separate values (columns) in the .csv file. Most popular delimiters are comma (,), semicolon (;) and tab character ( ), however other symbols can be used as well. At the previous sample page we have noticed that comma symbol was used as delimiter and values were quoted with " symbol. Specify two first settings as shown above.
    2. Note .csv file contains data in row - column format and delimiter character are used to separate one column from another. If you specify incorrect delimiter, the file will not be parsed properly and the products will not be imported.
    3. Category delimiter character is not native .csv setting, it is used only in Store Manager. As you know, categories are organized in a form of tree, where parent category can contain one or more subcategories, and subcategory, in its turn, is divided into one or more other category. Category delimiter character is used to separate category names and specify full category tree path for given category. See Step 1 - category column. Category path is very similar to directory path used to specify full file name in Windows, where every directory is separated by backslash (\) character like in the following example C:\Program Files\eMagicOne\Store Manager for Zen Cart\.
    4. As for example, category path for "Sample Subcategory" (see image below) will be Hardware|Graphics Cards|Sample Subcategory. Pipe (|) character was used as separator.

7. Image Import Options

    • Upload images - Enable the option in order to upload images to you server via FTP. Please make sure that you have specified correct FTP details in Tools -> Preferences -> FTP tab.
    • Apply default settings to all images - Allows you to configure default settings to all images.
    • Default Images Path - Can be used only for images or product descriptions in combination with "Is External" option. If image name or description file name are incomplete i.e. they do not contain full path including drive letter or "http:// prefix along with domain name (for images only), this default path will be added to image or description file path. If image name ( or description) contains full path, then this option may be ignored, unless you checked "Keep file path" option (for images only). You can specify local directory path here or HTTP directory URL ("http://www.someimagestorage.com/images/products/ )
    • Images Sub Folder - Allows to set path to Images Sub Folder at your FTP.
    • Keep Image File Path - Allows you to keep image path and upload images into sub folders. Should be used with Default Images Path option. For example, specify default images path as: C:\temp\Images if your .csv file contains full image path on your local PC and looks like shown in the following example - C:\temp\Images\imagesubdirectory\imagename.jpg, where \imagesubdirectory is images sub directory(eis) that you would like to create on your server and upload images to. Also subdirectories names should match the sub directory(ies) on your local PC (where images are located on your desktop).
    • Default Resize Rule - Allows you to specify resizing rules for images.

8. The next page allows you to Link columns from .csv file to appropriate database fields.

The left pane "Database Fields" shows the list of fields in your database that can receive data after Zen Cart import.

First row in .csv file contains field names, but not values - Obviously this option should be checked if first row of .csv file contains data, otherwise uncheck this option.

Products Identification Method - It is the topmost option as Zen Cart import will search for a product using selected method of identification. The product will be modified if found, if not - a new product will be added. Lets say you choose Identify Products By Product ID - how it is performed:

Import takes first row of the .csv file and retrieves value from a .csv column assigned to Product ID field. As you can see above, the Product ID field is assigned to the 1st column from your file and the value is "1"

Import tries to find product with ID of 1 in your store:

- If product was found, it will modify and set all values from .csv columns of the first line to assigned fields (even if you have let's say some Camera or Keyboard saved under the 1st ID, it will set values from your .csv file). Note that this method cannot be used if IDs in your file are different from the ones in your database

- if product with ID 1 is not found it will create new product, assign ID automatically (let's say you already have 983 products in your database, so the ID for this product will be 984) and set all values from assigned columns to that new product.

The same is true for Product Model and Name + Model identification methods, except that model and name can be updated in your database from your .csv file.

Note: It is required to assign .csv columns to key fields depending on identification method.

Important Note! Source .csv file can contain multiple records with identical data for identification values (for example same model number for multiple products). All these products (with same ID or Model) will be considered as one. Currently imported to shopping cart product will overwrite previously imported with the same key field values. Note that sometimes one of key fields may be blank. Obviously blank fields contain the same value for all records, thus only one prouduct will be updated.

Database Fields show the list of fields in your database that can receive import data. Database Fields contain the following columns:

    • Name - contains database field name. Some values in this column contain actual field name, whereas the other are "translated". Anyway these names are clear enough to figure out how to use them.
    • csv column - the number of the column in .csv file corresponding to this field - the link between database field and .csv column.
    • Set Null - indicates that this field should not contain any data, but should be set to Null. You can either specify column name or check this option, but not both of the actions at one and the same time.
    • Set Default - this option is used to set some default value to a field, similar to Set Null, but in this case some value can be assigned to a field.
    • Default - enter the value assigned to a field.
    • Expression - can be used for calculations while Zen Cart import. It is a good idea to use expressions to calculate the price (add 20% to your supplier's price), add quantity to your current stock (add new products to your current stock), etc. Please see an article for details.

To assign .csv column to database field you should select a field at the left pane and then click a column at the right pane.

[Auto Fill...] button - try to set the correspondence automatically for all fields. Auto fill option will work only if .csv column name is the same as database field name ("translated").

[Clear] button - clear all "csv col" values at the left pane.

Click "Next" if you're done.

To import attributes from separate columns you should create additional attribute field for each attribute. Once it is created, you will get 4 additional options: Option, Value, Prefix, Price. You need to assign attribute value, prefix and price for each attribute column of your file to appropriate attribute options of database in each additional field.

The next page of Import Wizard includes Base Formats and separators. They can be set by default.

Products were not imported to your Zen Cart database yet. At Import Preview page you can see how .csv file was processed using import settings, which you specified at the previous steps. Check whether all the columns that you want to be imported are filled with data: some of them may be blank. That means that either you haven't assigned .csv column or it is empty in source (.csv) file. Columns that were not assigned will not be imported whereas empty values will overwrite the existing ones.

Preview import step

Red blinking arrow called 'Show errors' will be shown to draw your attention if any errors occur.

Import options page settings may affect Import results. Please read and check your selection carefully.

Import options

Default category. If category name is specified in .csv file and column is assigned to database field, Store Manager will create entire category tree for a product. If there's no "category name" column (in .csv) or it is not assigned, all products will be imported to a category specified as Default. If default category is not specified and there's no other way to determine which category products should be imported into, program will create "Default category" and place all new products there.

Default manufacturer is set almost in the the same way as for category, except that product may not have manufacturer at all - it is not important. Also you can uncheck option in case you do not want to create new manufacturer if currently imported does not exist in database. Or check the field that will help to create the new manufacturer after importing.

Manufacturer options

Delete existing Attributes when importing new - if checked, import will clear all current product attributes and then add new. If unchecked it will just add new - this may cause duplicate attributes.

Mark unlisted products as "Out of Stock" ( in Zen Cart this is "In Stock" property of a product) - all products that were not affected by import will be marked as unavailable, but will not be deleted.

Cache import data - this option may speedup import process. How does it work?

Store Manager does huge number of database operations while importing products to Zen Cart store. There are many tables affected by Zen Cart import and a lot data should be processed. With slow database connection it may take too long - several hours or even days - depending on number of records and connection speed. If cache option is checked, Store Manager will generate database backup file - the same you can do using Backup/Restore wizard with "Product related tables only" option. After the backup is generated, program restores this backup on local database. All further import operations will be made locally, much faster than through remote connection. After import is completed it will generate another backup - from local database and then restore this backup on your remote store.

    1. With "Cache import data" option import procedure will show several backup/restore progress dialogs - this is common behavior.
    2. Note: Cache import data option is ignored when you currently connected to Embedded database.
    3. Import Method
    4. Add and Modify - will add new product if it is not available in database yet and modify those products that were found.
    5. Add Only - this option only adds new products.
    6. Modify Only - this option only updates the existing products and do not add new entries, even if current product was not found.
    7. Just Add - this option may produce product duplicates, since Store Manager will not try to find existing products but will only add all products as new
Import method

Save Import Configuration

All import settings can be stored under some configuration. You can load it next time you decide to import products to Zen Cart from a file with similar formatting, column names etc.

Save configuration file name

Also you can shutdown computer after import complete.

Attention! Import process will start, when you press "Import" Button! Proceed only if all the settings are made, otherwise press "Back" button and check settings once more!

In the last window of Zen Cart Import Products Wizard will be shown if any errors occurred during import process.

Most frequent import errors are date, time and number conversion issues, caused by invalid format settings (specified at the previous pages) or improperly assigned column (i.e. if you assign column containing category ID to parent_category database field).

Date/time conversion errors might be ignored whereas other errors like this one (Could not find image: image_name.gif) has to be fixed.

If you need assistance with import configuration, we'll gladly help you to setup everything correctly for additional fee. Please contact us at contact[at]zencart-manager[dot]com for details.

Zen Cart - Import Products Wizard

By eMagicOne Inc.