Function Problems

How to Calculate Packaging Weight by Part Number using Excel Formulas

Elise WilliamsElise Williams Nov 10, 2026 869 views

Question details

The user needs a dynamic formula to calculate the total packaging weight for various part numbers based on packaging types and the required quantities of lids, pallets, and collars.

How to Calculate Packaging Weight by Part Number in Excel
Product
Excel
Device & OS
not provided
Scenario
Managing logistics, shipping, or inventory data where component weights differ depending on the packaging type assigned to specific part numbers.
Observed behavior
Requires a solution to cross-reference the correct component weights for a given packaging type and multiply them by the required component quantities to yield the total weight.
Before you start

Ensure your spreadsheet is organized with two clear sections: a data table tracking the part numbers and component quantities, and a separate reference matrix that lists the exact weight of each component (lids, pallets, collars) per packaging type.

Solution 1Recommended

Use MMULT, INDEX, and XMATCH to Calculate Total Weight

This advanced array formula looks up the packaging type associated with the part number and multiplies the required quantities by their corresponding component weights in one efficient step.

Combining MMULT with INDEX and XMATCH creates a powerful matrix multiplication formula. It avoids the need to write long, repetitive addition formulas for every single component.

1
Select the output cell

Click on the cell where you want the total calculated weight for the first part number to appear (for example, cell J3).

2
Enter the formula

Type the formula: =MMULT(E3:H3,INDEX($B$12:$E$15,0,XMATCH(B3,$B$11:$E$11))). Adjust E3:H3 to match your component quantities, $B$12:$E$15 to match your weight reference matrix, and $B$11:$E$11 to match your packaging type headers.

3
Apply the formula

Press Enter to calculate the total weight for the first item.

4
Fill the formula down

Click the small square at the bottom-right corner of cell J3 and drag it down to automatically calculate the packaging weights for the remaining part numbers.

Use MMULT, INDEX, and XMATCH to Calculate Total Weight
How the formula works: XMATCH locates the correct packaging type column. INDEX retrieves the corresponding weights for that packaging type. MMULT then multiplies your quantities array by the weight array and sums the results instantly.
Efficient Data Calculation in WPS

Easily Manage Logistics and Inventory Data with WPS Spreadsheet

WPS Spreadsheet fully supports advanced array functions like MMULT, INDEX, and XMATCH, making complex logistics, shipping, and inventory calculations a breeze.

  1. 1. Open WPS Spreadsheet: Launch WPS Office, create a new Spreadsheet, and input your logistics and component weight tables.
  2. 2. Apply Advanced Formulas: Use the formula bar to seamlessly enter lookup and matrix math functions like MMULT and INDEX.
  3. 3. Save and Share: Save your document in standard .xlsx format to ensure it remains perfectly compatible with Microsoft Excel users.
Fully compatible with Microsoft Excel formulas and functionsFree, lightweight, and fast spreadsheet processing for large datasetsBuilt-in templates for inventory and logistics managementCross-platform support across Windows, Mac, Linux, and mobile
microsoft office alternative - wps office

Frequently Asked Questions

Why is my MMULT formula returning a #VALUE! error?

The #VALUE! error in MMULT typically occurs when the number of columns in the first array does not match the number of rows in the second array. Double-check your data ranges to ensure the quantity array (e.g., E3:H3, which is 4 columns) aligns perfectly with the weight array (e.g., a 4-row matrix returned by INDEX).

Can I use XLOOKUP or VLOOKUP instead of INDEX and XMATCH?

Yes, if your reference table is formatted differently, you can use XLOOKUP or VLOOKUP to find the weight of each individual component, multiply it by the quantity, and add them together (e.g., =Qty1*VLOOKUP(...) + Qty2*VLOOKUP(...)). However, the MMULT method is much cleaner and more efficient for multiple components.

Are XMATCH and MMULT fully supported in WPS Spreadsheet?

Yes, WPS Spreadsheet supports both XMATCH and MMULT, ensuring complete compatibility with modern array formulas used for complex data analysis in Microsoft Excel.