Others

How to Create Product Bundles with Automatic Codes and Prices in Spreadsheets

Adam DavisAdam Davis Oct 29, 2026 869 views

Question details

The user needs to generate every possible combination of configurable product options to create product bundles, automatically calculating each bundle's complete product code, combined description, and total price.

How to Create Product Bundles with Automatic Codes and Prices in Spreadsheets
Product
Spreadsheets
Device & OS
not provided
Scenario
Managing an e-commerce catalog or inventory where users must generate all possible variations of customizable products from separate option lists.
Observed behavior
A method is required to generate the Cartesian product of multiple option lists, concatenate the corresponding text strings, and sum up the individual prices into a new dataset.
Before you start

Ensure your individual product options, including their respective base codes, descriptions, and prices, are organized in separate, clearly labeled data tables before attempting to generate combinations.

Solution 1Recommended

Use Power Query to Generate Product Combinations

Power Query is the most efficient and robust way to generate a Cartesian product (all combinations) of multiple data tables without writing complex code.

By utilizing the cross-join functionality within Power Query, you can automatically pair every item in your first option list with every item in the second. You can then easily add custom columns to calculate the final price and concatenate the product codes.

1
Format Lists as Tables

Select your first product option list (e.g., Base Product) and press Ctrl+T to format it as a Table. Repeat this for your second option list (e.g., Accessories).

2
Load Tables into Power Query

Click anywhere inside your first table, go to the 'Data' tab, and select 'From Table/Range'. In the Power Query Editor, go to 'Close & Load To' and select 'Only Create Connection'. Do the same for the second table.

3
Create a Cross-Join

Open the first query in the Power Query Editor. Go to 'Add Column' > 'Custom Column'. In the formula box, simply type the exact name of your second query (e.g., = Accessories) and click OK. This adds a column containing the entire second table in every row.

4
Expand and Calculate

Click the double-arrow icon on the header of the new custom column to expand the fields (select Code, Description, and Price). Now, go to 'Add Column' > 'Custom Column' again to create your combined fields (e.g., =[Base Code] & "-" & [Accessory Code] for the product code, and =[Base Price] + [Accessory Price] for total price).

5
Load the Result

Once your complete product codes, combined descriptions, and total prices are calculated, go to 'Home' > 'Close & Load' to place the generated bundle list into a new worksheet.

Use Power Query to Generate Product Combinations
Data Updates: If you add new options or change prices in the original tables, you only need to right-click the output table and select 'Refresh' to update all bundles instantly.
Generate Combinations Easily

Automate Product Bundles with WPS Spreadsheet

WPS Spreadsheet offers powerful data management tools, including advanced formulas and easy-to-use table management, helping you generate product combinations, format text strings, and calculate totals effortlessly.

  1. 1. Open Your Data: Launch WPS Spreadsheet and open your workbook containing the product option lists.
  2. 2. Set Up Output Columns: Create designated columns for your target data: Complete Code, Description, and Price.
  3. 3. Apply Formulas: Use standard formulas like =A2&"-"&B2 for codes and =C2+D2 for prices.
  4. 4. Auto-Fill Data: Double-click the bottom-right corner of the formula cells to instantly apply calculations across thousands of bundle combinations.
Supports advanced array formulas for managing massive inventory datasets.Fully compatible with Microsoft Excel (.xlsx) formats and functions.Free, lightweight, and fast alternative for seamless catalog management.Intuitive UI for easy text concatenation and cross-sheet referencing.
microsoft office alternative - wps office

Frequently Asked Questions

What is a Cartesian product in spreadsheets?

A Cartesian product is a mathematical operation that returns a set from multiple lists where every item from the first list is paired with every item from the second list. In inventory management, this generates all possible product combinations and variations.

How do I combine text from multiple cells to make a single product code?

You can use the ampersand symbol (&) or the CONCAT function. For example, the formula `=A2 & "-" & B2` will join the text located in cell A2 and cell B2, placing a hyphen between them.

Can bundle prices update automatically if individual option prices change?

Yes. If your bundle total price column uses formulas that reference the original option tables (e.g., using a simple addition formula or lookups), any updates you make to the base option prices will automatically trigger a recalculation of the bundle totals.