LOOKUP THAT DEALS WITH MULTIPLE ROWS

surkdidat

Well-known Member
Joined
Oct 1, 2011
Messages
597
Office Version
  1. 365
I have the below code, which looks up a reference number, and then populates another sheet if the value is in that row. (This code works fine if every ID was only referenced once, howeve,r it falls out when more than one row with the same ID

However, there can be more than one row with the same reference number in the "Published" sheet, ie 10001, could be on rows 1,2,3, then 10002 just on row 4 etc.

I need this adapting so the match in the Published sheet, rather than having a row lookup (ie 8) does a match in column A of the Published Sheet, against column I in the ENG1 / Data Heet (column I)

Excel Formula:
=IF(ISNUMBER(
MATCH('DATA'!Q$2,Published!8:8,0))=TRUE,
INDEX('ENG1'!Q:Q,MATCH('DATA'!$I9,'ENG1'!$I:$I,0),),"")


'PUBLISHED
IDDETAIL_1DETAIL_2DETAIL_3
10001ColourSizeMaterial
10002Colour
10003ColourMaterial

ENG1
COLUMN ICOLUMN QCOLUMN RCOLUMN SCOLUMN T
IDColourSizeMaterial
10001Yellow555Metal
10002Brown
10003Red
10003RedPaper


PUBLISHED (What I need)
COLUMN 1COLUMN qCOLUMN RCOLUMN S
ID (Already on Sheet for Look Up)ColourSizeMaterial
10001Yellow555
10002Brown
10003Red
10004RedPaper
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
In other words ENG1 and Published have to mirror the cell content. So Q3 matches on both sheets, Q4 matches both sheets, R3 matches R3 etc.
 
Upvote 0
Solution
I have solved my own question by using a separate sheet and copying all the IDS, and then INDEX(MATCH this against the attribute sheet, so whenI come to do a replica, it looks up the exact row in the data
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,176
Members
453,021
Latest member
Justyna P

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