TEST MODE
Show details for 4 _ Multipart CSV Pricing Script

4 _ Multipart CSV Pricing Script

This Product

This sample product showcases the ability to split pricing data into multiple CSV documents for a single product.

Our example CSV's only contain a few entries per CSV, however this functionality is intended for use when the possible configurations number in the thousands.

When the configuration of product attributes (such as A & B) are changed, the Infigo system has to look up the updated pricing information from the provided CSV. For very large CSV's (over 1000 entries as a general rule of thumb), this can take a noticable amount of time.

By splitting one large CSV into multiple smaller CSV's, we can ensure the loading time is decreased.

This functionality relies on several entries in the pricing script configuration:

  • subDirectory | A folder created within Infigo's Global Additional Data area, in which your partial CSV's will be placed.
  • baseFileName | A common prefix on all of the partial CSV's uploaded to your subdirectory.
  • separator | A common delimiter located in the name of all of your partial CSV files.
  • splitMapping | Identification of the attribute(s) by which the CSV's are split. In our example, the splitMapping is set to "B" and there is a different partial CSV for each possible value of the "B" attribute.

Pricing script configuration

{
    "filePath": "",
    "quantityColumnName": "Quantity",
    "baseFileName": "Subdirectory",
    "subDirectory": "Subdirectory",
    "separator": "-",
    "splitMapping": ["B"]
}

Pricing script CSV

Subdirectory-1

A B Quantity Price
1 1 1 2
2 1 1 3
3 1 1 4
4 1 1 5
5 1 1 6
6 1 1 7

Subdirectory-2

A B Quantity Price
1 2 1 3
2 2 1 4
3 2 1 5
4 2 1 6
5 2 1 7
6 2 1 8

Subdirectory-3

A B Quantity Price
1 3 1 4
2 3 1 5
3 3 1 6
4 3 1 7
5 3 1 8
6 3 1 9

Subdirectory-4

A B Quantity Price
1 4 1 5
2 4 1 6
3 4 1 7
4 4 1 8
5 4 1 9
6 4 1 10

Subdirectory-5

A B Quantity Price
1 5 1 6
2 5 1 7
3 5 1 8
4 5 1 9
5 5 1 10
6 5 1 11

Subdirectory-6

A B Quantity Price
1 6 1 7
2 6 1 8
3 6 1 9
4 6 1 10
5 6 1 11
6 6 1 12
A *
B *
£2.00