Help with Vlookup to report 2nd 3rd 4th etc Matches

Marsman

Board Regular
Joined
May 13, 2013
Messages
62
Office Version
  1. 365
Platform
  1. Windows
I have been reading post after post and cannot quite figure this out.

I need to be able to do a Vlookup without changing any data as "Helper Columns" etc.

As with the following example "Sheet 1" is where is am trying to have the info populate and "sheet 2" is the Data set.

Obviously when I do "Vlookup" it is finding the information for the 1st record and pasting it into the follwoing record.

The only common column would ever be Column A. the Data in Columns B and C would change consistantly.


Sheet 1
ABC
1P20LPIValue needed
2P20PFValue needed
3P20SCAValue needed
4p19LPI
Value needed​
5P20FC
Value needed​
6P16SCA
Value needed​
7P19DS FEC
Value needed​

<tbody>
</tbody>

<tbody>
</tbody>

<tbody>
</tbody>


Sheet 2


ABC
1P20LPIDS RX
2P20PFUS
3P20SCAUS TX
4p19LPIDS RX
5P20FCNR
6P16SCAUS RX
7P19DS FECDS

<tbody>
</tbody>
 
And you are decided not to affirm whether they are DS RX and US for the first two occurrences of P20...

the issue is the Data in Column B is a small list of different types (around 12 types total) then the data in Column C can be upwards in the area of around 100 different categories.

This is why I was wondering if there was a formula/array to be able to report what is associated with each record "P20" in column A.
 
Upvote 0

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
In Cell B1 (Sheet1):
=IFERROR(INDEX(Sheet2!B$1:B$7,SMALL(IF((Sheet2!$A$1:$A$7=$A1)*(Sheet2!B$1:B$7<>""),ROW(Sheet2!$A$1:$A$7)-ROW(Sheet2!$A$1)+1),COUNTIF($A$1:$A1,$A1))),"-")

Copied Cross and Down

Azumi
 
Upvote 0
In Cell B1 (Sheet1):
=IFERROR(INDEX(Sheet2!B$1:B$7,SMALL(IF((Sheet2!$A$1:$A$7=$A1)*(Sheet2!B$1:B$7<>""),ROW(Sheet2!$A$1:$A$7)-ROW(Sheet2!$A$1)+1),COUNTIF($A$1:$A1,$A1))),"-")

Copied Cross and Down



Azumi

This code works great.

Thanks
 
Upvote 0

Forum statistics

Threads
1,214,950
Messages
6,122,436
Members
449,083
Latest member
Ava19

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