2.18. Import Products
The Store Manager Import Wizard will greatly facilitate the updating of your Store database via a simplified and efficient set of routines and applications.
Be sure to pay careful attention to each Wizard's page, to ensure the correct import of products into Prestashop. Prestashop import, depending upon the extent and number of operations to be performed, can be a rather complicated procedure, and it may be destructive, if performed incorrectly. Be sure to create a database backup before importing products, especially if this is the first time that you are performing this task. The first step is:
Prepare a File
The import wizard of Store Manager for Prestashop supports the following file's formats as CSV, XML, XLS, XLSX, ODS. Make sure that all necessary fields, and all data that you are going to import, are listed in the table.
Here's a list of fields that your file may include, along with a detailed description of those fields:
Reference - is a field required by Prestashop for all products. It is composed of a standard, alphanumeric string, that uniquely identifies the product, and is typically assigned to the product by the manufacturer. This procedure is used internationally. You should be able to obtain the standard code for all your products, if not already included, by requesting the information from your supplier. This field must have unique values, and may be used for identifying products during the Prestashop import. See step 6, for more about product identification.
Product ID - this is internal database field, it should be of numeric type only and must have unique values across entire table. The value from selected 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).
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.
Status - this field acquires "1" or "0" 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 not updated. Products that are not listed in .csv file can be set as "Out of Stock", if you enable appropriate option at the last step of Magento import.To set the value as in stock for all products you can specify 1 value for first product in your file and spread it for all products.
Quantity - you can set product quantity here. Please note that if you indicate "0 " or leave this field blank the product will be displayed at the your store's front end as "Out of Stock".
Category - specify the category your product belongs to. If the product should be imported into subcategory use pipe character "|" to separate parent and subcategory, for example: "Computers|Keyboards" - the product will be assigned to Keyboards category.
If you need to assign the same product to multiple categories, use double delimiter, in your .csv file. Here is the example: "Computers|Keyboards||Computers|Other". After that the product will be assigned both to Keyboards and to Other category while Prestashop 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 and is used to specify full file name in Windows, where every directory separated by backslash (\) character, like in the following example:
C:\Program Files\eMagicOne\Store Manager for ...\
In case your supplier provides you with the file that has categories in a separate columns, you can merge them to get appropriate format using Expressions field or you can merge them using Excel manually. Please follow these steps to merge categories using Expression field (is recommended to use with Automated Product Import for Prestashop):
At the fifth step “Assign .csv Columns to Database Fields" of Import Wizard find the “Category Name” field.
Set the following expressions for this fiel
CONCAT([CSV_COL(1)], '|', [CSV_COL(2)], '|' , ... , [CSV_COL(N)])
[CSV_COL(N)] is the separate column of .csv file with the category name (N is the column number or sort order)
| - is category delimiter (which has been chosen at the previous step)
Complete the Prestashop Import and check categories.
In order to merge category columns in Excel use the following formula:
| - is category delimiter
B2 - is your parent category column in file and
C2 - is sub category column in file.
"Import images" option allows to import one or more images for the product.
You may upload pictures from your local computer or external web URLs. 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.
In case you need to import the multiple images within one product, in the file to import should be specified the image gallery column with the ';' between each image positions. For example, the one product with two local images assigned should have the next record in the appropriate column of a file:
The first image's path /f/a/fabia.jpg separate with the second one /f/a/fabia-overview-6reasons-bottom.jpg with the ';' character.
Following this method, you can specify as many pictures as you want to the specific product.
It would be better to designate columns for base, small and thumbnail images in a file to import and do not forget to assign each of them to the appropriate fields of your store database during importing:
The images will be appointed in accordance with the specified positions after the import process:
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.
If you want to synchronize Prestashop products with your supplier automatically on a schedule, you may be interested in Automated Product Import addon.
We also offer additional features of import procedure - click here and find out more about it.
This Wizard will help you to make update of your database with modified PrestaShop products data by selecting appropriate action.
When you import products to PrestaShop pay attention to each Wizard's page. PrestaShop 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 first time.
To start PrestaShop Import Products procedure you need to click on Import/Export button in the top toolbar of Store Manager:
Launch Import wizard
The first window offers you two operations - export and import.
Import procedure in Store Manager allows to download necessary data from a file of csv, xml, xls, xlsx, ods, txt and xml formats to your store.
Click the [Import] button to move to the second stage of the process - the choice of file to import.
At this point please remember some important conditions:
- If you choose a local file to import - check whether the file is readable and openable.
- If you import file from HTTP URL - this file should be opened in web-browser.
- If you choose file from FTP URL - you should have the correct FTP settings.
Button [Load Settings] allows to use a previously saved import configuration in order to simplify the import process. Click the [Next] button to proceed.
Select fields delimiter and quote character
Current page contains some important settings. If you specify wrong values, PrestaShop products import may not work.
First option is delimiter character. Most popular delimiters are comma (,), semicolon (;) and tab character ( ) however other symbols can be used as well.
Note: csv file contains data in row - column format and delimiter character is used to separate one column from another. If you specify incorrect delimiter, file will not be parsed properly and products will not be imported.
Take into account the two positions on this page.
- "Use ID as category path". This option, if you check it, allows to place imported data to the categories, which are specified in a file by using their IDs as identifier.
Look at the example of this file below:
The path of items replacement represents by IDs instead of categories names. Please note, the multiple assignment product to the several categories should be indicated by double delimiter in the path as you can see in our illustration - example above.
In this case, check the option field and proceed with the following import steps:
Use the guide about particular option for detailed information :
"Keep current categories associations". Select this check-box if you need to leave products, which are transferring, in the existing categories positions at your store and add them to the new one, specified in the import file as well.
There are three tabs in the bottom:
"Images" - default images path is the place where store manager will look for images when importing products - image names specified in .csv file whereas image files stored here.
When store manager is unable to find an image it will not import image information to a product and will remove existing image information if any.
"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.
"Skip images..." field allows to skip those products which have already specified the appropriate images and add images to the items which are not assigned to any media files:
"Downloadable Files" serves for downloadable items during importing. Check the checkbox and specify the path where the downloadable files are placed.
Use the browse button to find necessary location.
"Attachments". If the products, which are importing, contain any attachments (as the additional information on the product(s)), check the field and specify the path, where the attachments are located, in the following tab.
Check the following article for better understanding how to add the attachments during products import:
Base Formats and Separators
The next PrestaShop Import Wizard page includes base formats of date values and numbers and separators between them. They can be set by default (button [Set Default])
The next page allows you to Link columns from file to appropriate database fields. The left pane "Database Fields" shows the list of fields in your database that can receive import data.
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.
Note, if you leave field with quantity not assigned, the default quantity value equals to 0 will be created by Store Manager as an import result.
[Auto Fill...] button - try to set correspondence automatically for all fields. Will work only if file's column name is the same as database field name ("translated").
[Clear] button - clear all "csv col" values at the left pane.
The topmost option on this page is First row in file contains field names but not values. Obviously it should be checked if first row of file contains data, otherwise un-check this option.
Next option is "Identify products by", PrestaShop Import will search for a product using selected identify method. The product will be modified if found, if not - new product will be added.
"Identify combinations by". If you have combinations of data to be imported, you should notice required method depending on the available combinations. You can choose one of the five options on their own or select the recommended one or just skip it, checking the "Skip combination import" variant.
Please note, if you select "Regenerate Product Combinations" checkbox you get the newly-created product combinations with overwritten prices, quantities and other combination data.
If items in a file have the additional related positions - i.e. accessories (like a handbag-clutch for the evening dress or coulomb to the chain) choose the identifier for such positions as well by opening the drop down list.
There are two available identifier - EAN or Reference - check which one is used in your import file.
Do not forget to assign columns with accessories to the appropriate field of your store database and indicate the correct identifier by which the program will recognize the products accessories during importing (as you can see in the illustration below).
For more extended display data in the certain fields or to summarize values in this fields (for example calculation of product price, available quantity etc) you can use the expression editor.
In the Expression column opposite the selected database field in the left pane press [Editor] button to call "Expression Editor" form.
To verify the correctness of entered expressions using the 'Execute Expression' button or press F9 key.
Click [Next] if you're done.
Supplier Reference in Importing
If the products of the store have the Supplier References specified you caen use such parameter as an identifier during importing. It can be possible in the latest updated version of Store Manager for Prestashop (from v.220.127.116.119 and higher).
Make sure all necessary data is properly selected in the file before running import process. Go through the import steps to the assignment stage.
The "Identification Methods" area is in the upper side of the current window:
Choose "Supplier Reference" and allow Store Manager to recognize import data by this parameter.
Move ahead to the final step of the import process, where you can check the supplier/suppliers which the particular changes will be applied to.
Preview import data
On "PrestaShop Import Preview Data" page you can see how .csv file was processed using import settings, which you specified at previous steps.
Check whether all columns that you want to be imported are filled with data: some of them may be blank. This means that either you haven't assigned .csv column or it is empty in a source (.csv) file.
Columns that were not assigned will not be imported whereas empty values will overwrite existing.
PrestaShop Import options page settings may affect on Import results. Please read and check your selection carefully.
Choose the method you want to perform via importing:
- "Add and Modify". Add new positions and update the existing ones.
- "Only Add". Create new products, search for the existing ones but do not modify them.
- "Modify Only". Only update the existing products and do not add the new ones.
- "Just Add". Add new items without searching for the existing ones.
Choose an action you want to be applied to the data that is not in the source (import) file from the variants listed below:
The products' association to the particular supplier during importing can be indicated on the current page of import wizard starting from the last update of Store Manager (version 2.39.0:1861).
So, by choosing the one of the conditions in the fields for data, which are not related to the source file, you are able to choose also a supplier where this condition will be applied to (see the illustration below):
"Shop associations" area. Check the store(s) in which the data will be modified after importing.
"Category option" area.
You can indicate which exact category the data will be placed to by using the browse button and expanding the category tree :
You can ignore the category path specified in a file and use the most relevant way for placing data (by the category name) by selecting the following checkbox:
You should pay attention to the column "Product Name". If it is absent in the import file and therefore was not assigned at the appropriate step of import process,
choosing the following import option - "Just Add" - you will get the error message:
Action cannot be performed due to the missing required column "Product Name" in your source file.
Using [Save Import Settings" button you can save current import configurations to a .cfg file and apply them during the next import procedure.
In 'Category Options' section you can assign a category which the data will be imported in or check box below and the data will be placed into the most appropriate category of your store.
Attention! Import process will start, when you press [Import] button! If all settings are made correct then continue the procedure, otherwise press [Back] button and check settings once more!
The last window of Prestashop Import/Export Wizard displays results and errors, if any emerged in the course of the import process.
Most frequent import errors are date, time and number conversion issues, caused by proper format settings (specified at previous page) 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.
Now PrestaShop Product Import process is completed.
Check the video tutorial below, which introduces the main steps of import procedure:
Also you can check related articles on PrestaShop Import here :