Lookup, index, match :-(

crackod93

Board Regular
Joined
Aug 9, 2007
Messages
71
sorry for creating a 2nd thread, looks like the original has been lost in the forum and i still really need help please

ive created a sample excel for this which can be found here which kind of shows what i want to do

https://dl.dropboxusercontent.com/u/...85/sample.xlsx

source tab has the data source
output tab has the desired output

im trying the find the first occurrence of X12 on Source tab, then where the row under that column contains a 1, pull out the Name_## and show all Name_## where this is true for every single row where 1 is found under that column

thanks again!
 

Excel Facts

Round to nearest half hour?
Use =MROUND(A2,"0:30") to round to nearest half hour. Use =CEILING(A2,"0:30") to round to next half hour.

StefanVL

Board Regular
Joined
Mar 7, 2013
Messages
146
sorry for creating a 2nd thread, looks like the original has been lost in the forum and i still really need help please

ive created a sample excel for this which can be found here which kind of shows what i want to do

https://dl.dropboxusercontent.com/u/...85/sample.xlsx

source tab has the data source
output tab has the desired output

im trying the find the first occurrence of X12 on Source tab, then where the row under that column contains a 1, pull out the Name_## and show all Name_## where this is true for every single row where 1 is found under that column

thanks again!

Link seems to be broken
 
Upvote 0

crackod93

Board Regular
Joined
Aug 9, 2007
Messages
71
the ...85 part of the url should be replaced with this

59255085

looks like the forum doesnt allow this
 
Upvote 0

StefanVL

Board Regular
Joined
Mar 7, 2013
Messages
146
There sure is a faster way to do this other than this but this is my go at it:

=IFERROR(INDEX($A:$A;SMALL(IF(SUMIF($A$2:$A$27;$A$2:$A$27;OFFSET($A$2:$A$27;0;MATCH(R$15;$B$1:$M$1;0);ROWS($A$2:$A$27);SUM(IF($B$1:$M$1=R$15;1;0))))=0;"";ROW($A$2:$A$27));ROWS($R$16:R16)));"")

enter with ctrl+shift+enter

I made this one the same tab as the input by the way.
 
Last edited:
Upvote 0

spoon_db

Board Regular
Joined
Jun 12, 2014
Messages
66
Array formula, start from row 2...

=INDEX($A$2:$A$27;SMALL(IF($B$2:$B$27>0;ROW($B$2:$B$27)-1);ROW()-1))
 
Upvote 0

crackod93

Board Regular
Joined
Aug 9, 2007
Messages
71
There sure is a faster way to do this other than this but this is my go at it:

=IFERROR(INDEX($A:$A;SMALL(IF(SUMIF($A$2:$A$27;$A$2:$A$27;OFFSET($A$2:$A$27;0;MATCH(R$15;$B$1:$M$1;0);ROWS($A$2:$A$27);SUM(IF($B$1:$M$1=R$15;1;0))))=0;"";ROW($A$2:$A$27));ROWS($R$16:R16)));"")

enter with ctrl+shift+enter

I made this one the same tab as the input by the way.


I managed to get this one working (unfortunately not the array one), but what is the reference to R16 for please???
 
Upvote 0

StefanVL

Board Regular
Joined
Mar 7, 2013
Messages
146
I managed to get this one working (unfortunately not the array one), but what is the reference to R16 for please???

The R16 works for the second part of the small formula. The first part gives an array of every row that has the correct name, which means row 11, 13, 14 and 17 in the array. By using rows(r16:r16) u can automatically choose the first smallest, the second smallest, etc.

You can also try this by just putting in =ROWS($R$16:R16) hovering over the formula and pressing F9. You'll then see 1 in the first cell, 2 in the second and so on.
 
Upvote 0

crackod93

Board Regular
Joined
Aug 9, 2007
Messages
71
The R16 works for the second part of the small formula. The first part gives an array of every row that has the correct name, which means row 11, 13, 14 and 17 in the array. By using rows(r16:r16) u can automatically choose the first smallest, the second smallest, etc.

You can also try this by just putting in =ROWS($R$16:R16) hovering over the formula and pressing F9. You'll then see 1 in the first cell, 2 in the second and so on.

awesome, thank you very much and to everyone else who took a look!!
 
Upvote 0

Forum statistics

Threads
1,191,025
Messages
5,984,197
Members
439,877
Latest member
kellylet

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
Top