using excel to convert from a per part BOM to a per line BOM - Page 1
Forum section: electronics / general

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 12:18:17 pm
content: I have a BOM that lists each part individually (as t has the coordinates of the part locations), but my assembler wants for quotation purposes a BOM that groups each part on a line.Is there a way to achieve this in Excel ?

author: PA0PBZ
author_rank: Super Contributor
timestamp: January 25, 2017, 12:33:23 pm
content: Without having seen the spreadsheet (so I could be wrong) you can use the subtotal function for that.You will have to sort on partname before doing that.

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 12:38:25 pm
content: yes each part that is identical has an identical name. So I need to look up how to use the subtotal function. Thank you.

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 01:00:45 pm
content: no it won't work as I have the same parts randomly scattered in the BOM

author: rs20
author_rank: Super Contributor
timestamp: January 25, 2017, 01:08:30 pm
content: Quote from: Simon on January 25, 2017, 01:00:45 pmHence why PA0PBZ suggested to use sort first.Failing anything else, this'd be straightforward enough to write a VBA macro to do.

author: PA0PBZ
author_rank: Super Contributor
timestamp: January 25, 2017, 01:09:14 pm
content: I'll PM you my email address, if you can send me the spreadsheet I'll show you how to do it.

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 01:16:30 pm
content: attached is the spreadsheet. Sorry I missed the bit about sorting that I don't know how to do either.

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 01:22:02 pm
content: although to be fair the guy that produce the bom has not always been consistent in naming

author: PA0PBZ
author_rank: Super Contributor
timestamp: January 25, 2017, 01:22:44 pm
content: Is this the result you are looking for?

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 01:28:32 pm
content: yes perfect (if the names are consistent) so how is it done ? Actually I should probably do it on RS or farnell codes as they are my choice (1% and 5% resistors have been consolidated for example)

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 01:41:22 pm
content: ok I think I have it

author: PA0PBZ
author_rank: Super Contributor
timestamp: January 25, 2017, 01:58:28 pm
content: Quote from: Simon on January 25, 2017, 01:41:22 pmIt's a bit hard to explain because my Excel is in Dutch- make sure you have no joined cells- sort the sheet on the column you want the subtotal on- use the subtotal on the data tab to do the job. Probaby play around with the settings and see what happens

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 02:31:23 pm
content: Right so sorting is done but subtotalling is a bit weird, will have to read up on the options I need

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 02:41:16 pm
content: Got it to work eventually but it only seems to work on the first column

author: PA0PBZ
author_rank: Super Contributor
timestamp: January 25, 2017, 02:43:29 pm
content: Quote from: Simon on January 25, 2017, 02:41:16 pmIn the subtotal dialog window you can specify the column that has to be subtotalled and the column where the subtotals should be placed.

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 02:54:03 pm
content: yea and it just says that every item of data exist only once. as soon as I do it on column A it works

author: RoGeorge
author_rank: Super Contributor
timestamp: January 25, 2017, 03:06:48 pm
content: I guess you need what is called a Pivot Table.Excel can do Pivot Tables, so it is possible to count/sum/average/whatever.

author: PA0PBZ
author_rank: Super Contributor
timestamp: January 25, 2017, 03:17:11 pm
content: I have no problem doing it for both the RS and Farnell columns, see attached.

author: Simon
author_rank: Unknown
timestamp: January 25, 2017, 03:19:25 pm
content: Well I will have to carry on playing. Is there a way to remove the "anatal" or in my case "count" from the resulting column ? if I could do that I'd have the exact part numbers and number of parts each

author: iainwhite
author_rank: Unknown
timestamp: February 03, 2017, 11:51:15 am
content: Bit late to the party but i did a sample sheet with 2 extra tabs containing pivot tables.Tab 'Pivot1' is a pivot of column 'Value' with counts of parts with the same valueTab 'Pivot2' has 2 pivot tables - one for RS part numbers and one for Farnell part numbers.I hope this is some use and gives you some ideas.PS I had to put the file in a zip because forum doesn't allow .xlsx filesEdit: I added a pre-Excel2007 version of the sheet as an .xls file

author: Simon
author_rank: Unknown
timestamp: February 03, 2017, 01:24:40 pm
content: Thank you I will take a look. Having talked to our supplier I think in the future we are going to have to have 2 bill of materials.

author: T3sl4co1l
author_rank: Super Contributor
timestamp: February 03, 2017, 05:14:51 pm
content: What are you producing the BOM from? Can it not generate lines properly?A listing with coordinates sounds, not like a BOM, but a Pick-and-Place table. You wouldn't usually have MFG/PN data in there.Tim

author: Simon
author_rank: Unknown
timestamp: February 03, 2017, 05:22:01 pm
content: Yes indeed. All I had at the time to go on was the bill of materials with individual pick and place locations which is what would be supplied for manufacturing purposes. In the future I will make sure I get a bill of materials and a separate pick and place file although it would probably still include a lot of information about each part.