The single most seen message by users is probably the "Incorrect column count".
The incorrect column count means that the columns CSV Improved has found in your file is not the same as the columns in your configuration. Let's clarify this with some examples.
The CSV file looks like this:
"product_sku","poduct_name","category_path"
The template has delimiters set to:
Field delimiter: ^
Text delimiter: ~
Having incorrect delimiters makes it impossible for CSV Improved to read your file. As CSV Improved looks for the ^ character but it cannot find one, it will read the complete line as a single field. This cannot be identified as a supported field and as a result it gives the error message. Always make sure the delimiters match.
The CSV file looks like this:
product_sku,poduct_name,category_path
PROD1,Product 1,Products/Software,
The field delimiter used is a comma, this means we have a total of 3 fields:
The product information we want to import has a total of 4 fields:
Now we can clearly see that there is an incorrect column count because 3 is not the same as 4. Why are there 4 fields for the product information? As we use the comma as field delimiter, after every comma a new field starts. So the comma after Products/Software also creates a new field. The trailing comma must be removed. Always check your file for trailing field delimiters.
The CSV file looks like this:
product_sku,poduct_name,product_name,category_path
PROD1,Product 1,Product 1,Products/Software
The field delimiter used is a comma, this means we have a total of 3 fields:
The product information we want to import has a total of 4 fields:
Since the product_name field already exists already the same name again is ignored. This leaves you with 3 fields to import while the data contains 4. Either rename or remove the column to solve the issue.
The CSV file looks like this:
product_sku,product_name,category_path,product_publish
PROD1,Product 1,Products/Software
The field delimiter used is a comma, this means we have a total of 4 fields:
The product information we want to import has a total of 3 fields:
Here we have a situation where the configuration fields are more than the data fields. What happens is that in a spreadsheet program like Excel a cell is not exported until it is "touched". In this case the column header product_publish was added but no value was put in for the product. To solve this the cell must be given a space or anything actually so it becomes a used cell after that it will be exported.
It is possible to use the column headers in a file to tell CSV Improved what fields you want to use. There is another way and that is to assign fields to the template used for import via the templates menu.
The CSV file looks like this:
PROD1,Product 1,Products/Software
The template fields assignment looks like:
product_sku
product_name
attribute
category_path
This means we have a total of 4 fields:
The product information we want to import has a total of 3 fields:
This is another situation where the configuration fields are more than the data fields. The solution here is to remove the assigned fields that are not being used.