keelaboosa
New Member
- Joined
- Apr 3, 2018
- Messages
- 35
I've got a BOM in the following format:
[TABLE="class: grid, width: 250"]
<tbody>[TR]
[TD]Item
[/TD]
[TD]Description
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]Pants
[/TD]
[/TR]
[TR]
[TD]1.1
[/TD]
[TD]Right Pants Pocket
[/TD]
[/TR]
[TR]
[TD]1.1.1
[/TD]
[TD]Keys
[/TD]
[/TR]
[TR]
[TD]1.1.2
[/TD]
[TD]Change
[/TD]
[/TR]
[TR]
[TD]1.1.3
[/TD]
[TD]Phone
[/TD]
[/TR]
[TR]
[TD]1.2
[/TD]
[TD]Left Pants Pocket
[/TD]
[/TR]
[TR]
[TD]1.3
[/TD]
[TD]Back Pants Pocket
[/TD]
[/TR]
[TR]
[TD]1.3.1
[/TD]
[TD]Wallet
[/TD]
[/TR]
[TR]
[TD]1.3.2
[/TD]
[TD]Comb
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]Hat
[/TD]
[/TR]
[TR]
[TD]3
[/TD]
[TD]Shirt
[/TD]
[/TR]
[TR]
[TD]3.1
[/TD]
[TD]Right Shirt Pocket
[/TD]
[/TR]
[TR]
[TD]3.2
[/TD]
[TD]Left Shirt Pocket
[/TD]
[/TR]
</tbody>[/TABLE]
I want to turn into this format for a pivot table
[TABLE="width: 162"]
<tbody>[TR]
[TD]
[TABLE="class: grid, width: 300"]
<tbody>[TR]
[TD]L1
[/TD]
[TD]L2
[/TD]
[TD]L3
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD]Keys
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD]Change
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD]Phone
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Left Pants Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Back Pants Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Back Pants Pocket
[/TD]
[TD]Wallet
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Back Pants Pocket
[/TD]
[TD]Comb
[/TD]
[/TR]
[TR]
[TD]Hat
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Shirt
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Shirt
[/TD]
[TD]Right Shirt Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Shirt
[/TD]
[TD]Left Shirt Pocket
[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]I've figure out how to split the Item column from the first table using Power Query, but I'm at a loss how to get the correct Descriptions in the appropriate cells.
Any ideas?
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[TABLE="class: grid, width: 250"]
<tbody>[TR]
[TD]Item
[/TD]
[TD]Description
[/TD]
[/TR]
[TR]
[TD]1
[/TD]
[TD]Pants
[/TD]
[/TR]
[TR]
[TD]1.1
[/TD]
[TD]Right Pants Pocket
[/TD]
[/TR]
[TR]
[TD]1.1.1
[/TD]
[TD]Keys
[/TD]
[/TR]
[TR]
[TD]1.1.2
[/TD]
[TD]Change
[/TD]
[/TR]
[TR]
[TD]1.1.3
[/TD]
[TD]Phone
[/TD]
[/TR]
[TR]
[TD]1.2
[/TD]
[TD]Left Pants Pocket
[/TD]
[/TR]
[TR]
[TD]1.3
[/TD]
[TD]Back Pants Pocket
[/TD]
[/TR]
[TR]
[TD]1.3.1
[/TD]
[TD]Wallet
[/TD]
[/TR]
[TR]
[TD]1.3.2
[/TD]
[TD]Comb
[/TD]
[/TR]
[TR]
[TD]2
[/TD]
[TD]Hat
[/TD]
[/TR]
[TR]
[TD]3
[/TD]
[TD]Shirt
[/TD]
[/TR]
[TR]
[TD]3.1
[/TD]
[TD]Right Shirt Pocket
[/TD]
[/TR]
[TR]
[TD]3.2
[/TD]
[TD]Left Shirt Pocket
[/TD]
[/TR]
</tbody>[/TABLE]
I want to turn into this format for a pivot table
[TABLE="width: 162"]
<tbody>[TR]
[TD]
[TABLE="class: grid, width: 300"]
<tbody>[TR]
[TD]L1
[/TD]
[TD]L2
[/TD]
[TD]L3
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD]Keys
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD]Change
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Right Pants Pocket
[/TD]
[TD]Phone
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Left Pants Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Back Pants Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Back Pants Pocket
[/TD]
[TD]Wallet
[/TD]
[/TR]
[TR]
[TD]Pants
[/TD]
[TD]Back Pants Pocket
[/TD]
[TD]Comb
[/TD]
[/TR]
[TR]
[TD]Hat
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Shirt
[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Shirt
[/TD]
[TD]Right Shirt Pocket
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Shirt
[/TD]
[TD]Left Shirt Pocket
[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD]I've figure out how to split the Item column from the first table using Power Query, but I'm at a loss how to get the correct Descriptions in the appropriate cells.
Any ideas?
[/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
[TR]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]