How to transpose when it matches

mediumrare

New Member
Joined
Apr 7, 2021
Messages
31
Office Version
  1. 365
Platform
  1. Windows
Hello, and thank you for clicking on this.

I have a sample spreadsheet for an upcoming inventory project. It has 24,000 lines of products on it. The software we use is able to give me each product that was on an invoice, but I need to put each product on the same row on not on the same column. (Attached is a screenshot. The light grey is where they were and the black is where they should be.

I hope there is a solution for this? I can't tell from my searches whether this is suited for TRANSPOSE, INDEX, MATCH, etc. and how best to apply those to this scenario.


Thanks in advance.
 

Attachments

  • mba-test_transpose-issue.png
    mba-test_transpose-issue.png
    59.6 KB · Views: 6

Excel Facts

How can you turn a range sideways?
Copy the range. Select a blank cell. Right-click, Paste Special, then choose Transpose.
Added Xl2bb for a test area.

Market Basket Analysis TEST.csv
ABCDEFGHIJK
17444735B204IMP
18444735B225
19444735B880B
20444735BITW91930CT
21444735B134761
22444735B291
23444735B4050
24455699ASP-7106
25455699A76835
26455699AUS950N-AMB
27455699AAMBUSLAV
Market Basket Analysis TEST
 
Upvote 0
Should there be a new row for each distinct value in col A?
 
Upvote 0
Should there be a new row for each distinct value in col A?

Yes, that would be ideal. Each "invoice number" (A) will not have a duplicate "product number" (B), so there would ideally be a new row for each cell that matches each invoice number.

I hope I'm making sense here!
 
Upvote 0
Ok, how about
+Fluff 1.xlsm
ABCDEFGHIJKL
17444735B204IMP444735B204IMP225880BITW91930CT1347612914050
18444735B225455699ASP-710676835US950N-AMBAMBUSLAV
19444735B880B
20444735BITW91930CT
21444735B134761
22444735B291
23444735B4050
24455699ASP-7106
25455699A76835
26455699AUS950N-AMB
27455699AAMBUSLAV
28
Main
Cell Formulas
RangeFormula
D17:D18D17=UNIQUE(FILTER(A17:A1000,A17:A1000<>""))
E17:K17,E18:H18E17=TRANSPOSE(FILTER($B$17:$B$1000,$A$17:$A$1000=D17))
Dynamic array formulas.
 
Upvote 0
Solution
Ok, how about
+Fluff 1.xlsm
ABCDEFGHIJKL
17444735B204IMP444735B204IMP225880BITW91930CT1347612914050
18444735B225455699ASP-710676835US950N-AMBAMBUSLAV
19444735B880B
20444735BITW91930CT
21444735B134761
22444735B291
23444735B4050
24455699ASP-7106
25455699A76835
26455699AUS950N-AMB
27455699AAMBUSLAV
28
Main
Cell Formulas
RangeFormula
D17:D18D17=UNIQUE(FILTER(A17:A1000,A17:A1000<>""))
E17:K17,E18:H18E17=TRANSPOSE(FILTER($B$17:$B$1000,$A$17:$A$1000=D17))
Dynamic array formulas.

Thank you, thank you, thank you!

I also think I understand how this formula works too, which is a bonus in and of itself!
 
Upvote 0

Forum statistics

Threads
1,215,067
Messages
6,122,949
Members
449,095
Latest member
nmaske

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