Manage multidimensional data in a table

Summary

Overview

Sometimes, it can be useful to present product information in a table, in order to ease the enrichment, improve the readability of the product sheet, and/or because it is required by law (for instance, to present the nutritional values of a product in the food industry).

This is why we've decided to create a new attribute type: the Table attribute.

Delete

This attribute type is available in the Growth Edition and in the Enterprise Edition.

How to create a Table attribute within Akeneo?

As for the other attribute types, you can create a Table by clicking on Settings > Attributes > Create attribute. Then, click on Table and choose among our templates, or build your own.

Delete

These templates are here to guide you. They are only presentation suggestions and can be edited to adapt to your needs. If you prefer to create your table from scratch, choose the Empty table template.

Once the template is selected, a pop-in appears, asking you to choose a code, a label, and sometimes a standard, depending on the template you just chose.

You'll discover a tab called Table structure: this is where you can define your columns.

Except for the Empty table template, some columns have already been created for you. You can add new ones, simply by clicking on Add new columns. 
For each new column, you must define a code, a label, and the type (select, number, text or yes/no). The column label can be translated in your catalog locales. You can also change the order of the columns, by clicking on the drag and drop area.

Finally, delete any column you don't need, by clicking on the trashcan (appearing when hovering the row).

Delete

Imagine you sell food products worldwide, and you need to add the nutritional values of your products. You know that nutritional tables formats will differ between countries or continents, and that they are regulated by national laws. Therefore, you'll need one nutritional table per geographical area: one for your American market, one for your European market, and a last one for the UK market. In this case, we recommend you to create 3 nutritional tables, with the locale specific parameter, in order to avoid having empty tables in some locales.

Let's discover the table attribute's particularities

We've defined several golden rules to structure a table attribute, in order to leverage the power of the PIM and the Akeneo logic.

A TABLE MUST CONTAIN AT LEAST 2 COLUMNS.

Each column is defined by a code, a label, and a type. The label can be translated into your catalog locales.

ONCE THE TABLE STRUCTURE IS DEFINED AND SAVED, IT CANNOT BE CHANGED AFTERWARD.

It means that your columns are frozen once you've clicked on Save. If you need to change the code or the type of a column, you must delete and re-create it.

THE FIRST COLUMN IS ALWAYS A SELECT ONE.

To structure your table, you can choose among 4 column types:

  • Select
  • Yes/No(boolean)
  • Number
  • Text

Nevertheless, the first column type must always be Select  one.

We will detail how these 6 column types work in the next section.

Specificity of each column type

SELECT COLUMN TYPE

Just like for the Simple select and Multi select attribute types, you can define options for your Select column type. 
For instance, if your table attribute is used to list the ingredients of a product, each ingredient is an option of your Select column, this way you will be able to use it in the Product Edit Form. Check out our dedicated article to discover how to use rows in your product page. You create the options once, and you use them as much as you want in your product tables 😉.

Delete

The sorting of the options in the manage options screen is based on their creation date, in order to guarantee the best performances of your PIM.

Directly from the manage options screen, you can add options coming from a simple or multi-select attribute as an option for your table, just by clicking on the Import from existing attribute button.

Delete

Note that imported options are not synchronised but are a one-shot copy of existing attribute options. Adding or removing options from the selected simple or multi-select attribute won't change the options of the table column.

Delete

If an option already exists on the table option list (same code), all the labels of this option will be replaced by the imported option.

Furthermore, if, while importing options, the table option list exceed the 20000 options limit threshold, all the remaining options will be ignored and won't be imported.

TEXT COLUMN TYPE

In the Text columns, you can define the maximum number of characters, in order to control the length of your cells' content. 
Of course, you cannot define a negative value, and moreover, you are limited to 100 characters by the system. In other words, this parameter lets you define a maximum number of characters between 1 and 100.

NUMBER COLUMN TYPE

In the Number column type, you can specify the minimum value, the maximum value and if you allow decimal values or not.

YES/NO (BOOLEAN) COLUMN TYPE

There is no validation parameters in this column type!

Scalability of a table attribute

In order to ensure that the PIM keeps running, we have defined some limits.

  • You can create up to 10 columns in a single table.
  • You can create up to 20000 options within a Select column.
  • You can have up to 100 rows per table attribute in a product sheet.
  • You can create up to 50 table attributes in your PIM.
  • You can have up to 8000 filled cells in a product sheet (including all table attributes)

History tab

Just like the other attribute types, there is an History tab. 
In this tab, we track the activity on your attribute such as:

  • any change in the attribute properties tab
  • any change in the table structure tab, except if you update the option's labels (within a select column).
  • any change in the label translations tab

Import/export your table data

Import/export the table structure

IMPORT/EXPORT THE COLUMNS

You can import/export a table attribute just like any other attribute types, by using the attribute import or attribute export profiles. But, the structure of your table (i.e, the columns of your table) must be written in a JSON format, and inserted in the dedicated column of your import/export file, called table_configuration.

Delete

We are aware that this JSON format is not ideal, but there is no other easy way to proceed as of today. That's why, if you need to make some changes via XLSX or CSV files, we recommend you to export your attributes first, fix what needs to be, and re-import it.

Delete

If you prefer to use the API, please note that the table configuration is part of the Attribute endpoint. To learn more about it, you can refer to our API documentation.

We've developed dedicated import/export profiles for the options of your select column types 😉.

IMPORT/EXPORT THE OPTIONS OF YOUR 'SELECT' COLUMNS.

Because it would have been a nightmare to mix up the columns configuration and the options of the Select columns in the same file, we've decided to create distinct import and export profiles for the options: the table option import and table option export, both in CSV or XLSX format. To know more about imports, please check out the dedicated article, and for exports, everything you need to know is in this article.

Delete

And if you are comfortable with the API, you can retrieve the table options within the Attribute endpoints, as you can see in our API documentation.

Delete

When exporting lots of options in XLSX, please note that the export will fail if the total number of characters exceed 32,767 per cell.

Import/export the table values of a product

Exactly like for other attribute types, you can import and export your products with table attributes. CSV and XLSX formats are structured as tables. Therefore, to import the Akeneo PIM table attribute value, it must be formatted in a single cell of your import using the JSON format. This way it’ll be imported along with any other regular attribute values. It’s faster but more technical.

USING "PRODUCT DATA TABLE VALUES" IMPORT/EXPORT JOBS

There is another way, more readable and easier to configure using dedicated export and import jobs for the table attribute. It will only handle table attribute values and it will be formatted as they are in the product edit form.

These dedicated jobs are:

  • Product table values import and export (csv and xlsx)
  • Product model table values import and export (csv and xlsx)

We recommend you to create one import profile per table attribute you want to import/export. Indeed, these jobs enable you to import/export the table values of several products sharing the same table attribute. For imports, as each table attribute can have a different structure, we don’t want to import files mixing up tables with different structures. For exports, you need to choose a single attribute for each job.

For instance: you manage your composition with a table attribute in your "food" family. You can create a new import profile called food composition, that uses the product data table values job, in order to import the composition values of several food products at a time.

What about the completeness?

You can define that a table is required for the completeness of a channel. Check out our dedicated article for more information.

The ground rule is that we consider a table complete as soon as one cell is filled. You can go further by defining the completeness at the column level by making it required for the completeness of the attribute.

This way, you can easily define three different levels of completeness:

  • the table is complete if every cell is filled (you should have checked the completeness option in every column)
  • the table is complete if every cell of at least one column is filled (you should have checked the completeness option for one or several columns)
  • the table is complete as soon as one cell is filled. In that case, only the completeness option of the first column should be checked. This is the default behavior.

Now that you know all the secrets of the Table attribute type, let's discover its capabilities in the Product Edit Form!