CSV is an acronym of "Comma-separated values". It is an popular plain-text format when there is a need to import, export or simply store data in a non-proprietary format. Almost all data handling tool support CSV format, in various incarnations. You can read more about the CSV format on Wikipedia: http://en.wikipedia.org/wiki/Comma-separated_values.
The CSV import page enables you to easily fill your product catalog when you have a very large amount of products, or to import data that you exported and converted from another e-commerce tool.
The import process requires preparation, and starts with a form made of primary settings:
/docs/csv_import
folder of your installation of PrestaShop.When changing the Entity setting, the section on the right, titled "Available fields", changes to present the expected data fields. Although the importing tool helps you by taking care of matching your file's fields with PrestaShop's, you should strive to make your data more import-friendly by following the naming scheme and order of the presented fields. If not, the import will be more tedious, but not impossible.
Some fields have a little information popup available on their right, which you can display by hover the mouse cursor over it. They mostly pertain to PrestaShop's multistore feature. Make sure to read them all in order to better build/edit your data files.
Imported data file must be in text-file, using a CSV-based format and the accompanying .csv
file extension. We recommend using a semicolon ";" as a separator.
You can create such a file using any text editor (we recommend Notepad++: http://notepad-plus-plus.org/), but we do advise you to use a spreadsheet program, then save your work in the CSV format. Using a spreadsheet program enables you to have an easier and more visual grasp of your data, in comparison to the plain text file. You can use the commercial Microsoft Excel (http://office.microsoft.com/en-us/excel/ or the free OpenOffice.org http://www.openoffice.org/ Calc.
Here is a sample import file, for a list of products:
"Enabled";"Name";"Categories";"Price";"Tax rule ID";"Buying price";"On sale";"Reference";"Weight";"Quantity";"Short desc.";"Long desc";"Images URL" 1;"Test";"1,2,3";130;1;75;0;"PROD-TEST";"0.500";10;"'Tis a short desc.";"This is a long description.";"http://www.myprestashop/images/product1.gif" 0;"Test 02";"1,5";110;1;65;0;"PROD-TEST2";"0.500";10;"'Tis also a short desc.";"This is a long description too.";"http://www.myprestashop/images/product2.gif" 1;"Test 03";"4,5";150;1;85;0;"PROD-TEST3";"0.500";10;"'Tis a short desc. again";"This is also a long description.";"http://www.myprestashop/images/product3.gif" |
Note that this is only a regular sample files built for this demonstration; it is purposefully not optimized for PrestaShop importation. If you need a sample file you can learn from, use the ones you can download from the "Upload" button's form.
The first row should be a descriptive name for the data column (you will be able to skip it during the import process). There must be the same number of columns on each row.
You should remember that:
2013-06-21 15:07:27
.Once you have all your data in CSV format, you can upload them to your store's database using the form in this page. Choose your file(s) from your computer by clicking on the "Upload" button, click the "Browse" button to find your file, then click the "Upload" button to mark it as chosen. Do this as many times as necessary to list all your import files.
Once your files are all listed in the "Your CSV file" section, you can proceed with the rest of the form:
All import files are uploaded directly in the admin folder's |
When clicking the "Next step" button, the page reloads with the matching tool. This interface helps you match you file's data columns with the ones required by PrestaShop.
Presented in this table are the rows from your CSV file, placed under arbitrary columns matched to PrestaShop's database needs. It is up to you to make sure that all the columns from your CSV file are matched with the correct column header, using each header's drop-down menu, so as to import your content correctly.
For instance, with our sample file:
The screen cannot contain all of your data's columns, so click the ">>" and "<<" buttons to move around the columns, and match them all correctly.
In our example, we used the first row for columns indicators. Since we do not this one imported, enter "1" in the "Skip X lines" text-field.
Once you are done matching your columns, click the "Import .CSV data" button (top right of the screen), and PrestaShop will start the importing process. When the process is done, you are sent to the main screen, which should either confirm that everything has indeed been imported, or give you a notice of all the encountered problems. In this second case, you should review your CVS file and make sure to correct everything.
The matching process can be a tedious task if you cannot customize your CSV files columns order according to that used by the PrestaShop importer, and even more so if you have to do that repeatedly or frequently. That is why PrestaShop includes a small tool to save the current matching order that you have set up using all the headers drop-down menus.
The tool is a simple field at the top of the matching tool. You can do the three basic actions: