0

My goal is to Match the Primary Key's of two different sheets in Excel. In this scenario, the primary key has multiple duplicates, but is differentiated with column TYPE.

What would be the way for me to Match the Primary Key to the correct key with only TYPE = 'A'?

=INDEX('SHEET 1'!C:C,MATCH(A2,'SHEET 1'!A:A)) This code is matching the primary key to both sheets to obtain name, however I do not know how to specify/match the TYPE = 'A' as well>

Image 1 with the code

Image 2Reference Data

Scott Craner
  • 148,073
  • 10
  • 49
  • 81

1 Answers1

0

Make a helper column in sheet1 with formula =A2&B2 It will give "x1A" "X1B"....

then use this formula: =INDEX(Sheet1!C:C,MATCH(A2&"A",Sheet1!E:E,0))

observe there is a Zero in the end of the Match function.

If someone knows how to do this without helper column, I would be thankful to see that solution.

WeAreOne
  • 1,310
  • 1
  • 2
  • 13