Use INDIRECT combined with INDEX MATCH (multiple row criteria) to return values from specified sheet

Bluefish74274

New Member
Joined
Dec 30, 2020
Messages
9
Office Version
  1. 365
Platform
  1. Windows
I know its possible to lookup and return the value from a cell on a specified worksheet within a workbook. I've done this before using INDIRECT combined with INDEX MATCH. However I am only able to get this to work when matching 1 row and 1 column. Can this be done if I have 2 rows and 1 column to match or would I need to use a different function? Please let me know if example is needed.

Thanks in advance for any guidance.
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
I know its possible to lookup and return the value from a cell on a specified worksheet within a workbook. I've done this before using INDIRECT combined with INDEX MATCH. However I am only able to get this to work when matching 1 row and 1 column. Can this be done if I have 2 rows and 1 column to match or would I need to use a different function? Please let me know if example is needed.

Thanks in advance for any guidance.
Here is sample of spreadsheets. Image #1 --- Master, Image #2 & #3 ---Lookup sheets called Health and Beauty, respectively
 

Attachments

  • Image1.PNG
    Image1.PNG
    15.3 KB · Views: 14
  • Image2.PNG
    Image2.PNG
    29.6 KB · Views: 15
  • Image3.PNG
    Image3.PNG
    31.5 KB · Views: 14
Upvote 0
Perhaps your sample is a bit brief, but I'm wondering if you need to check two columns. For your sample data & layout, what happens if you put this in cell C7 of 'Master'?
Excel Formula:
=FILTER(INDIRECT(B$4&"!C$3:N$10"),INDIRECT(B$4&"!A$3:A$10")=B$3,"")
 
Upvote 0
Perhaps your sample is a bit brief, but I'm wondering if you need to check two columns. For your sample data & layout, what happens if you put this in cell C7 of 'Master'?
Excel Formula:
=FILTER(INDIRECT(B$4&"!C$3:N$10"),INDIRECT(B$4&"!A$3:A$10")=B$3,"")
Thank you so much Peter! This works great! Once caveate. In the sample data I sent, the lookup tabs have 2 lines for each category (sales, margin). The real scenario has 3 lines (sales, margin, margin rate) but I only want to return sales and margin lines to the master tab. The formula you provided brings all rows over to master. Can this formula be tweaked or is there another formula that to accomplish my goal?

Regards,
Nancy
 
Upvote 0
Can this formula be tweaked or is there another formula that to accomplish my goal?
You could try the tweaked formula in C7 below or the replacement formula in C11 which could be copied down and see what suits you best (assuming they do what you want).
In either case you may need to adjust the ranges to match your data.

Bluefish74274.xlsm
BCDEFGHIJKLMN
3Cosmetics
4Beauty
5
6JanFebMarAprMayJunJulAugSepOctNovDec
7Sales259635225136
8Margin321752797164
9
10
11Sales259635225136
12Margin321752797164
13
Master
Cell Formulas
RangeFormula
C7:N8C7=TAKE(FILTER(INDIRECT(B$4&"!C$3:N$10"),INDIRECT(B$4&"!A$3:A$10")=B$3,""),2)
C11:N12C11=FILTER(INDIRECT(B$4&"!C$3:N$10"),(INDIRECT(B$4&"!A$3:A$10")=B$3)*(INDIRECT(B$4&"!B$3:B$10")=B11),"")
Dynamic array formulas.
 
Upvote 0

Forum statistics

Threads
1,224,737
Messages
6,180,643
Members
452,992
Latest member
TokugawaIesuma

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