CSV Examples
To gain a better understanding of how to import items into Bizzkit PIM using the CSV format, here are some simple examples. Please refer to the CSV specification for more information.
Products
Here are some examples of creating and modifying products through the importer.
Getting started
When importing products, use the UniqueName
header to either update an existing product or create a new one. Here is a simple example of creating or updating a product called PRODUCT1 with values for two attributes:
Merge and override mode
In Merge mode (UI and API), using the NULL value will ignore updating a specific attribute. Given two attributes called SINGLE_STRING and SINGLE_INT, the following CSV will create PRODUCT2 with values for both SINGLE_STRING and SINGLE_INT, whereas PRODUCT3 will only have a value for SINGLE_STRING:
In Override mode (API only), using the NULL value will assign a null value to the specific attribute.
Simple data types
Given simple data types like PString, PBoolean, PDateString, and PInt32, an import can be defined as:
Segmented data types
When importing segmented data, you can use the :C
, :T
, :M
, and :D
syntax where C = Channel, T = Translation culture, M = Market, and D = Device. Here is an example of importing data to the Translation culture and Channel dimension:
Note the use of :CCHANNEL2
, :Tda
, :Ten
, and Default
for the default value.
Multi-value
When importing data to multi-value attributes, you can use the array syntax []
to specify the attribute value by index (zero-based). Here is an example of importing two values to a multi-valued PString and PInt32 attribute:
Multi-field
When importing data to a single-valued multi-field attribute, you can use the slash syntax. Here is an example of importing values to a multi-field attribute:
Note the use of /
and then the system name of the field.
Global lists
When importing data with an attribute related to a data source (global list), you can import the key or value of the global list item. Given a global list with the key/values of:
Key | Value |
---|---|
ITEM1 | Item #1 |
ITEM2 | Item #2 |
Here is an example of using the key for both a single and multi-valued attribute:
Note the use of $
in the header to indicate that the value represents the key.
Here is the same example, but this time the importer uses the value because the $
before the attribute name is omitted.
Master and variants
When adding products in a master/variant hierarchy, you can use the VariantOfMaster
header. Here is a simple example:
This will create three products with a simple attribute where PRODUCT11
and PRODUCT12
are variants of PRODUCT10
.
Product placement
Using the PrimaryPlacementCategory
(and AdditionalCategoryPlacement_*n
if needed) header, you can place a product in a hierarchy node.
Given a product hierarchy as follows:
Here are simple examples of placing products in a category:
This will place PRODUCT13
in DEMO_2_LEAF11
as primary category.
This will place PRODUCT14
in DEMO_2_LEAF11
as primary category and in DEMO_2_LEAF12
as additional category.
Global list items
To import items to an existing global list, you can use the /api/global-lists/import/csv
endpoint. Here is a simple example of adding items to the global list named LIST1
:
When importing data using this format, the system name for every item is generated automatically. See CSV reference for more information.
Hierarchies
Importing hierarchies is only possible through the API and for CSV import you can use the /api/product-hierarchies/import/csv
endpoint. Here is an example of importing a simple hierarchy to the existing root node called TOYS:
This will add sub nodes to the TOYS hierarchy as follows:
Info
Please note that the root node of the hierarchy must exist before importing items. Use the UI or /api/product-hierarchies
endpoint.
Bundles
To import bundles, use the /api/products/bundles/import/csv
endpoint. Here is an example of importing two (existing) products called MYPRODUCT2
and MYPRODUCT3
to one (existing) product called MYPRODUCT1
.
Info
Use Remove
as ItemOperation
if you need to remove a bundled item.