Matching rows against rows based on one shared cell

steallan

Active Member
Joined
Oct 20, 2004
Messages
305
HI
If ive got two rows, which share the same info in one cell, can i match them against each other?

I.e got a big list of rows, a second big list of rows. I want to copy a row from the second list next to (horizontally) the first if the rows share the same value in one particular cell.

Is this possiblem its kind of like a vlookup function but instead of returning one cell it returns the whole row, or line of cells

thanks

:rolleyes:
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
Look at this example:
Book4
ABCDEFG
1nameValue1Value2Value3lvalue1lvalue2lvalue3
2abc125634100100010000
3def457654200200020000
4ghi238665#N/A#N/A#N/A
5
6
7
8
9
10namelvalue1lvalue2lvalue3
11abc100100010000
12def200200020000
Sheet1


The formula in E2 is:

=VLOOKUP($A2,$A$11:$D$13,COLUMN()-3,0)

which is copied down and across.

Using the COLUMN() enables the formula to be copied across to fetch successive columns. The 0 at the end ensures an exact match. The lookup data needs to be sorted ascending.
 
Upvote 0

Forum statistics

Threads
1,203,464
Messages
6,055,573
Members
444,799
Latest member
CraigCrowhurst

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