Skip to main content

Merge product variants into parent item with the Merge Variants service

Merge all product variants into one parent item using the Merge Variants service in Productsup.

Introduction

If you have child variants in your import feed and wish to work with one parent item, you can merge child variants into one parent item using the Merge Variants service.

Note

Ensure you have set a product identifier to use this service.

For example, your import data source may look similar to the following:

parent_id

child_id

size

color

1

1-1

XS

green

1

1-2

S

green

1

1-3

L

blue

2

2-1

XS

red

2

2-2

M

yellow

You would merge on the parent_id column, meaning you summarize or merge the data for all variants belonging to the same parent_id. The following example illustrates removing duplicates for each merged column. After applying the Merge Variants service, your output could appear similarly:

parent_id

child_id

size

color

1

1-1,1-2,1-3

XS,S,L

green,blue

2

2-1,2-2

XS,M

red,yellow

Add the Merge Variants service

To add the Merge Variants service:

  1. Go to Data Services from your site's main menu and select ADD SERVICE. Then choose Merge Variants, and select Add.

    add_merge_variants_service.png
  2. (Optional) In Name, give the new service a custom name.

  3. (Optional) Define a custom column prefix in Column prefix. The platform uses a column prefix when a service generates multiple columns from one service and needs a common prefix for all new columns.

  4. The Merge Variants service is only available on the import level for the Service Data Level function.

  5. Select Add.

  6. Select the Add Merge Column button to choose Source Column to select the column you want to merge with your variants. The source column is typically the parent_id or the item_group_id column.

  7. Choose a delimiter to separate the content after you perform a merge.

  8. (Optional) Select the Concat unique button to disable it if you don't want to remove merged duplicates.

  9. Select Save.

    merge.png

You can add multiple instances of this service by repeating the previous steps.

Edit an existing Merge Variants data service

  1. Go to Data Services from your site's main menu.

  2. Choose the Merge Variants data service and select the settings cogwheel icon ().

Delete an existing Merge Variants data service

  1. Go to Data Services from your site's main menu.

  2. Choose the Merge Variants data service and select the settings cogwheel icon ().

  3. Scroll to the bottom of the page and select Remove this service.