Index a table of data based on either 1 of 2 critria

nobbyclarke

New Member
Joined
Nov 25, 2015
Messages
24
Hi

We use a stop card system to report safety observations. I made a small statistics excel sheet to monitor the progress of closing out those cards.

the cards have three status' open, closed or in progress within the worksheet.

On the same worksheet I want to create a second table that automatically shows the user the cards that are "open" OR in "progress".

I have been using an array formula to work this out...

=IFERROR(INDEX(B$9:B$4003, SMALL(IF($AR$1=$K$9:$K$4003, ROW($K$9:$K$4003)-MIN(ROW($K$9:$K$4003))+1, ""), ROW(A2))), "")

AR1 is the 1st criteria (open)
AR2 not in above formula is the second criteria (in progress)

I have tried to add in the second criteria by the following....

=IFERROR(INDEX(B$9:B$4003, SMALL(IF(OR($AR$1=$K$9:$K$4003,$AR$2=$K$9:$K$4003), ROW($K$9:$K$4003)-MIN(ROW($K$9:$K$4003))+1, ""), ROW(A2))), "")

however this is not working and what I get back is a stop card that is actually closed.

so the question is how can I list all the stop cards that are currently in the "open" or "in progress" state (column K)???

please help.
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
Perhaps a pivot table would do what you need? Assuming the status is in one column and card number in another column.
 
Upvote 0
Change this :

=IFERROR(INDEX(B$9:B$4003, SMALL(IF(OR($AR$1=$K$9:$K$4003,$AR$2=$K$9:$K$4003), ROW($K$9:$K$4003)-MIN(ROW($K$9:$K$4003))+1, ""), ROW(A1))), "")

Into this :

=IFERROR(INDEX(B$9:B$4003, SMALL(IF(($AR$1=$K$9:$K$4003)+($AR$2=$K$9:$K$4003), ROW($K$9:$K$4003)-MIN(ROW($K$9:$K$4003))+1, ""), ROW(A1))), "")

Regards
 
Upvote 0
Assuming that the first formula instance goes in A2 and copied down...

=IFERROR(INDEX(B$9:B$4003,SMALL(IF(ISNUMBER(MATCH(K$9:$K$4003,$AR$1:$AR$2,0)),ROW($K$9:$K$4003)-ROW($K$9)+1),ROWS($A$2:A2))),"")

If this must be copied across, then replace ROWS with COLUMNS.
 
Upvote 0

Forum statistics

Threads
1,215,588
Messages
6,125,692
Members
449,250
Latest member
azur3

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