Mapping Fields to the Product CSV

Most of the fields in the Product CSV are self-explanatory and detailed information about the individual columns in the CSV can be found here :

http://docs.woothemes.com/document/product-csv-import-suite-column-header-reference/

We will go through how we can manage the product attributes and values.

 

We will start with the Parent Product

You can view the prepared csv for the Parent product here: demo-parent-product

Before we start, note that you should set the column header: “tax:product_type” to variable. If you intend to use the product as a variable product.

To include product attributes, you will need two column headers as follows:

attribute:pa_YOUR_ATTRIBUTE_NAME

  • This column manages the values of your attribute. In our example, the attribute name would be “color” and the  values of the attribute would be “black”,”space grey” and “gold”.

attribute_data:pa_YOUR_ATTRIBUTE_NAME

  • This column manages the attribute’s metadata. They are “Attribute Position”, “Enable for Display” and “Enable for Variation”. We will be going through this later.

You should replace the “YOUR_ATTRIBUTE_NAME” with an attribute name of your choice.

In our example, the attribute names are color and diskspace. The resulting csv would contain this:

column-headers

Now, we will need to fill in the information for each product. Under attribute:pa_color, we have three colors: “Black”,”Space Grey” and “Gold”. Under attribute:pa_diskspace, we have three sizes: “16GB”, “64GB” and “128GB”.

For attribute_data:pa_color, we have three different settings to enable for the attribute:

Attribute Data Description Accepted Values
Attribute Position The position at which you want the attribute to appear in relationship to other attributes Any Numerical Number
Display This will affect whether the attribute will be shown on the frontend of your site. 1 for display, 0 for not display
Used for Variations This is used only by variable products and ignored by other product’s types. 1 for used for variations, 0 for not used for variations

Each attribute settings should be separated by the pipe symbol “|”.

For example, we would like to have the color attribute as the first attribute position, display it on the frontend and use it for the iPhone 6 variation. Hence we would choose to enter 1|1|1 in the attribute_data:pa_color field. The resulting CSV should look like this:

column-filled

You can view the prepared csv for the Parent product here: demo-parent-product

 

Moving on to the Variations/Variable Products

You can view the prepared csv for the variable product here: demo-variations-product

Usually, the minimum columns you’ll need for your variations CSV will be the following:

  1. parent_sku or post_parent to map to a parent variable product
  2. sku for the variation
  3. regular_price / sale_price for the variation
  4. Meta Columns to map each variation to an attribute of the parent product

The meta columns define the attribute for each product and maps it to the parent product’s attribute values.

For example, in our example, there is a mixture of variable products as follows:

Color Diskspace
Black 16GB
Black 64GB
Black 128GB
Space Grey 16GB
Space Grey 64GB
Space Grey 128GB
White 16GB
White 64GB
White 128GB

The column header for the attribute would be in the following format: meta:attribute_pa_YOUR_ATTRIBUTE_NAME

You can fill in the column fields with an attribute value such as black for color or 128GB for diskspace.

In our example, the resulting CSV file will contain the following snippet:

meta-attributes

For more information about importing Variations, you may refer to the following article on the developer’s site: http://docs.woothemes.com/document/product-csv-import-suite-importing-product-variations/

You can view the prepared csv for the variable product here: demo-variations-product

 

Once you have the product variations set up, we are ready to move on to the next stage: Uploading the Products