Bill of materials quantity

nigelbloomy

New Member
Joined
Jul 2, 2012
Messages
9
I'm using Excel 2007 on Windows XP. I have many different Bill of materials that come to me in the format below. I would like a formula in column D that can tell me the total quantity that will be used to make the top level part. For example: For part e, I will use 1 * .6(at level 2) *1 (at level 1). So I will use a total of .6 of part e to make my top level part a.

I tried using sum product to find anything lower than each level. My problem with that is when I multiply the quantity of part e by all part levels lower than 3 I get the .6 from the correct level 2, but I also get the .5 from the the other level 2 (part b).

I have been trying formulas to do this, but I think it may need VBA code to get it right.


LevelPartQuantity
1a1
2b.5
3c.01
2d.6
3e1
4f.2
5g3
4h6

<tbody>
</tbody>

Thank you for your help.
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
Welcome to the board.

Code:
      --A-- -B-- ---C---- --D---
  1   Level Part Quantity  Ext  
  2      1  a          1      1 
  3      2  b        0.5    0.5 
  4      3  c       0.01  0.005 
  5      2  d        0.6    0.6 
  6      3  e          1    0.6 
  7      4  f        0.2   0.12 
  8      5  g          3   0.36 
  9      4  h          6    3.6

The formula in D2 and copied down is

=C2*IF(A2=1, 1, LOOKUP(2, 1/(A$1:A2=A2-1), D$1:D1))
 
Upvote 0
Welcome to the board.

Code:
      --A-- -B-- ---C---- --D---
  1   Level Part Quantity  Ext  
  2      1  a          1      1 
  3      2  b        0.5    0.5 
  4      3  c       0.01  0.005 
  5      2  d        0.6    0.6 
  6      3  e          1    0.6 
  7      4  f        0.2   0.12 
  8      5  g          3   0.36 
  9      4  h          6    3.6

The formula in D2 and copied down is

=C2*IF(A2=1, 1, LOOKUP(2, 1/(A$1:A2=A2-1), D$1:D1))

Nice!!!

M.
 
Upvote 0
Thank you, Marcelo. Or slightly differently,

=C2*IF(A2=1, 1, LOOKUP(9E307, D$1:D1/(A$1:A2=A2-1)))
 
Last edited:
Upvote 0
shg you are incredible. I have spent weeks trying to figure this out using offset, match and sumproduct functions. I don't know how to thank you enough for figuring this out so quickly.
 
Upvote 0
You're welcome, glad it helped.
 
Upvote 0
Hello, I'm using Excel 2010 and I have a similar problem for a more complex bill of materials.


My BOM use top level assemblies, sub-assemblies and sub-sub-assemblies, and sub-components.


For example:


Item Code Quantity


1 A 2


1.1 B 2


1.2 B2 4


1.2.1 B21 2


1.3 B3 2


2 C1 1


2.1 C4 5


I need to create a fourth column with the total quantity for the main assembly. So, for example, we will need 16 items from 1.2.1 (Multiplying 2 by 4 and by 2).


Is there a similar equation that we can use to calculate automaticaly?


Thank you very much!
 
Upvote 0

Forum statistics

Threads
1,214,653
Messages
6,120,752
Members
448,989
Latest member
mariah3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top