Lookup with multiple results in Google Sheets

hemitheus

New Member
Joined
Nov 1, 2017
Messages
6
I wish Excel were an option, but it isnt.

nELqQZT3xEu.png
nELqQZT3xEu.png
I need to be able to have a formula that looks at the data i enter in column P and references the table to the left and returns all of the times (Row 1) with matching results in the table.

Thank you in advance for your assistance.
<style type="text/css"><!--td {border: 1px solid #ccc;}br {mso-data-placement:same-cell;}--></style>
9:00 AM9:15 AM9:30 AM9:45 AM10:00 AM10:15 AM10:30 AM10:45 AM11:00 AM11:15 AM11:30 AM11:45 AM12:00 PMValue to Look UpResult 1Result 2Result 3
Many rows with other data that cannot be moved live here. sadly
MikePPPPPBPPPPPLLL
SuePPPPBPPPPLLPP
Example BobPBPPPPBPPPLLPL11:30 AM11:45 AM
I want to enter a value in column P and have the values from the

Named Range 'TIMES'

B1:N1
reflect in the columns Q,R,S,T,U etc...


<colgroup><col style="width: 84px"><col width="48"><col width="48"><col width="48"><col width="48"><col width="54"><col width="54"><col width="54"><col width="54"><col width="54"><col width="54"><col width="54"><col width="54"><col width="53"><col width="32"><col width="106"><col width="55"><col width="55"><col width="55"></colgroup><tbody>
</tbody>

<tbody>
</tbody>

<style type="text/css"><!--td {border: 1px solid #ccc;}br {mso-data-placement:same-cell;}--></style>
 

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
Array enter (ctrl+shift+enter) this for first result:

Code:
[TABLE="width: 64"]
<tbody>[TR]
[TD="width: 64"]=IFERROR(INDEX($A$2:$N$100,1,SMALL(IF($A$5:$A$100=$P$3,IF($B$5:$N$100=$P$4,COLUMN($B$5:$N$5))),COLUMN(A$1))),"")[/TD]
[/TR]
</tbody>[/TABLE]

Copy across for the other results.

Considering P3=Bob and P4=L
Or you can drag those data to other cells.

Godspeed!
 
Last edited:
Upvote 0

Thank you for the quick response.

In sheets it looks as follows:

=ArrayFormula(IFERROR(INDEX($A$2:$N$100,1,SMALL(IF($A$5:$A$100=$P$3,IF($B$5:$N$100=$P$4,COLUMN($B$5:$N$5))),COLUMN(A$1))),""))

I wish I could use Excel... Regardless. I entered this into Q3 as an array and entered the L in P3 and there was no result.

I modified your code to visually reflect an error as follows:

=ArrayFormula(IFERROR(INDEX($A$2:$N$100,1,SMALL(IF($A$5:$A$100=$P$3,IF($B$5:$N$100=$P$4,COLUMN($B$5:$N$5))),COLUMN(A$1))),"E R R O R"))

the result was Q3 was still blank.

Any thoughts?
 
Upvote 0
Thank you,

I did use this and it, sadly, did not work.

As I am forced to use sheets, the formula translates to the following:

=ArrayFormula(IFERROR(INDEX($A$2:$N$100,1,SMALL(IF($A$5:$A$100=$P$3,IF($B$5:$N$100=$P$4,COLUMN($B$5:$N$5))),COLUMN(A$1))),""))

Since it did not function I modified it to visually see the iferror function, if it were firing to this:

=ArrayFormula(IFERROR(INDEX($A$2:$N$100,1,SMALL(IF($A$5:$A$100=$P$3,IF($B$5:$N$100=$P$4,COLUMN($B$5:$N$5))),COLUMN(A$1))),"E R R O R"))

The "e r r o r" did NOT show, so that eliminates that possibility.

Any suggestions?
 
Upvote 0
I think that might be where the confusion is.

in column P the only entries possible will be blank, L, B, or P
Column A is for the names.

So each row is representative of the person in column A
Column P I would adjust in order to see what times the person had a L, B or P

It is also possible that you are right on the money with this and I am not following what you are saying.

Thanks
 
Upvote 0
I changed cell ref for Name. Array enter this in Q5 and copy across and down:

Code:
[TABLE="width: 64"]
[TR]
  [TD="width: 64"]=IFERROR(INDEX($A$2:$N$100,1,SMALL(IF($A$5:$A$100=$A5,IF($B$5:$N$100=$P5,COLUMN($B$5:$N$5))),COLUMN(A$1))),"")[/TD]
[/TR]
[/TABLE]

That
 
Upvote 0

Forum statistics

Threads
1,214,920
Messages
6,122,264
Members
449,075
Latest member
staticfluids

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