Hi, we are trying to tidy up some data and are working on reports which we get sent.
The information needs to be duplicated onto different rows based on the contents of the cell in Column B...
Column B is where the multiple Manufacturer Part Numbers (MPN's) are entered.
The MPN's have been trimmed of everything apart from their AlphaNumeric Characters and are separated by semi-colons. And there are semi-colon bookends at the beginning and end of each cell.
We have enclosed a small sample of data below to show a bit better what we are looking for (hopefully!).
Example Raw Information:
Results Sheet
Some of the challenges we have got are that there are 60 odd thousand rows and 45 of 50 columns on some of the reports that we are receiving.. and they're growing. (Hence why we are taking steps towards tidying them up!)
On the plus side, the structure of the files always remains the same:
Column A = the row number
Column B = the concatenated MPN's (always contained in that one single column)
Column C onwards contain the information
(And there's 1 header row)
Huge thanks for any help you can provide.
The information needs to be duplicated onto different rows based on the contents of the cell in Column B...
Column B is where the multiple Manufacturer Part Numbers (MPN's) are entered.
The MPN's have been trimmed of everything apart from their AlphaNumeric Characters and are separated by semi-colons. And there are semi-colon bookends at the beginning and end of each cell.
We have enclosed a small sample of data below to show a bit better what we are looking for (hopefully!).
Example Raw Information:
Raw Data | |||||||
A | B | C | D | E | F | G | H |
row | MPN-Original | Info-1 | Info-2 | Info-3 | Info-4 | Count of MPN's | Notes for The Results Sheet |
2 | ;ABC123; | blue | 11/06/2023 sold 10/11/2023 sold | 01/06/2023 bought 11/05/2022 | new source needed 14/12/2021 | 1 | For Row 2, only 1 MPN so no need for this info to change in the results sheet |
3 | ;XYZ789;501304; | Essex | 31/05/2019 herts 08/01/2023 move | 08/11/2021 essex | 2 | For Row 3, 2 MPN's so this would need to be duplicated onto 2 different rows on the results sheet | |
4 | ;XYZ789;501304; | 11/06/2023 herts | 01/01/2020 herts | 2 | For Row 4, 2 MPN's which are the same as row 3 BUT there are different entries in the information fields. It would need to be duplicated onto 2 different rows (NB the row number is different to the one above) | ||
5 | ;GHEPANJ874755;847834HFHF7;7569FT2YYT44D; | 11/06/2023 | allocated all stocks, now obsolete | 3 | For Row 5, 3 MPN's, so duplicated onto 3 rows | ||
Results Sheet
Results Sheet | ||||||
A | B | C | D | E | F | G |
row | MPN-V2 | Info-1 | Info-2 | Info-3 | Info-4 | Count of MPN's |
2 | ;ABC123; | blue | 11/06/2023 sold 10/11/2023 sold | 01/06/2023 bought 11/05/2022 | new source needed 14/12/2021 | 1 |
3 | ;XYZ789; | Essex | 31/05/2019 herts 08/01/2023 move | 08/11/2021 essex | 1 | |
3 | ;501304; | Essex | 31/05/2019 herts 08/01/2023 move | 08/11/2021 essex | 1 | |
4 | ;XYZ789; | 11/06/2023 herts | 01/01/2020 herts | 1 | ||
4 | ;501304; | 11/06/2023 herts | 01/01/2020 herts | 1 | ||
5 | ;GHEPANJ874755; | 11/06/2023 herts | allocated all stocks, now obsolete | 1 | ||
5 | ;847834HFHF7; | 11/06/2023 herts | allocated all stocks, now obsolete | 1 | ||
5 | ;7569FT2YYT44D; | 11/06/2023 | allocated all stocks, now obsolete | 1 | ||
Some of the challenges we have got are that there are 60 odd thousand rows and 45 of 50 columns on some of the reports that we are receiving.. and they're growing. (Hence why we are taking steps towards tidying them up!)
On the plus side, the structure of the files always remains the same:
Column A = the row number
Column B = the concatenated MPN's (always contained in that one single column)
Column C onwards contain the information
(And there's 1 header row)
Huge thanks for any help you can provide.