+ Reply to Thread
Results 1 to 4 of 4

Make Indented BOM into Flat BOM

  1. #1
    Registered User
    Join Date
    03-24-2022
    Location
    SD
    MS-Off Ver
    2016
    Posts
    2

    Post Make Indented BOM into Flat BOM

    Hello Everyone,

    I have been struggling with this problem for years and would greatly appreciate any support. Solidworks exports indented BOM's in the following parent child format.

    1 - Top most Parent
    1.1 - first child of parent
    1.1.1 - child of first child
    2 - second most parent
    2.1 - first child of second parent
    ..
    ..
    ..
    etc

    I have provided a simple example below:

    Number Item QTY
    1 Truck 1
    1.1 wheel 4
    1.1.1 rim 3
    2 axel 2
    2.1 brake 4
    2.1.1 brake fluid 6
    3 window 1
    4 Seat 1

    I want to find the QTY of items it takes to make the Truck. The answer is below

    ANSWER
    Truck 1
    wheel 4
    rim 12
    axel 2
    brake 8
    brake fluid 48
    window 1
    Seat 1

    How would you go about solving this for larger BOM's?
    Attached Files Attached Files

  2. #2
    Administrator 6StringJazzer's Avatar
    Join Date
    01-27-2010
    Location
    Tysons Corner, VA, USA
    MS-Off Ver
    MS365 Family 64-bit
    Posts
    24,721

    Re: Make Indented BOM into Flat BOM

    I understand what you are trying to do but there is not enough information in your worksheet to get the answer. For example, there is no place that says that there are two brakes per axle. Also I have no idea how you figured that you need three rims for 4 wheels.

    If you can provide that missing middle part I can give you a solution.
    Jeff
    | | |會 |會 |會 |會 | |:| | |會 |會
    Read the rules
    Use code tags to [code]enclose your code![/code]

  3. #3
    Registered User
    Join Date
    03-24-2022
    Location
    SD
    MS-Off Ver
    2016
    Posts
    2

    Re: Make Indented BOM into Flat BOM

    Hey Jazzer,

    Thanks for commenting on this, I appreciate that. This example was completely made up so the numbers don't particularly matter; I added an extra rim for clarity. I am only interested in the logic of how we arrive to the solution and how to utilize that logic on a much larger BOM. I have a BOM with 24 Parents and 800+ children and sub children that I need to flatten similarly to what I have shown below.

    Regarding the brake pads per axel, the Axel (Item 2) has QTY (2) and it's child the brake (Item 2.1) has a QTY (4). Therefore, to make one Truck it will take 2 axels and 8 brakes. One Axel needs 4 brakes, thus 2 axels need 8 brakes. Similarly, to have a complete Axel assembly, we need brake fluid. It takes 6 brake fluid to make one brake. So we need 24 fluid per axel but we have two axel's per car so the total is 48 units of brake fluid.

    Number Item QTY
    1 Truck 1
    1.1 wheel 4
    1.1.1 rim 4
    2 axel 2
    2.1 brake 4
    2.1.1 brake fluid 6
    3 window 1
    4 Seat 1


    I have attached another similar example.

    Number Item QTY Answer
    1 Chair 2 Chair 2
    1.1 Leg 4 Leg 8
    1.1.1 Rivets 16 Rivets 128
    2 Seat 1 Seat 2
    2.1 Rivets 4 Rivets 8
    Attached Files Attached Files

  4. #4
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 2019
    Posts
    17,565

    Re: Make Indented BOM into Flat BOM

    The following works for the Truck:Seat example in rows 5:12
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    The following works for the Chair:Rivets example in rows 19:23
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    I don't know how you would tell Excel that there is a difference between a Chair and a Truck however.
    My feeling is that if you want one formula for both scenarios, you may have to manually put the number of seats that would be needed for two chairs in the second example. You could then use the first formula for both as modeled in rows 26:30
    Let us know if you have any questions.
    Attached Files Attached Files
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. split an indented hierarchy
    By DeanMcK in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 12-06-2021, 09:27 AM
  2. Macro to compare two flat files and copy missing value to new flat file
    By pratheepm7 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 03-21-2017, 02:15 PM
  3. Create Flat BOM from indented BOM using macro/vba code
    By haugheym in forum Excel Programming / VBA / Macros
    Replies: 12
    Last Post: 01-10-2016, 03:27 AM
  4. Replies: 3
    Last Post: 08-01-2012, 06:00 PM
  5. Replies: 2
    Last Post: 06-15-2012, 12:22 PM
  6. Trouble Working with data. Trying to make it all flat
    By fasterthanyours in forum Excel General
    Replies: 8
    Last Post: 04-09-2012, 10:09 PM
  7. How to make a flat file?
    By Blairag in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-09-2009, 05:36 PM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1