Lookup (Index? Match?) First Instance of Condition in Column

screech

Active Member
Joined
May 27, 2004
Messages
296
I have two columns:

A | B
------
1 | 24
2 | 12
3 | 5
4 | 0
5 | 23
6 | 25
7 | 0
8 | 0
9 | 18

This is probably very simple, but what would the formula be to lookup the first instance of a "0" in column B and return the value in column A at that row. Example, find the first "0" in B, result would be "4". I've tried a variety of lookup, match, and index commands, but none seem to work just as it should.

Thanks!
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
book1
ABCD
1A240D
2B1225F
3C5
4D0
5E23
6F25
7G0
8H0
9I18
Sheet1


Values to look for in C, but could be incorporated into formula in D.

Formula in D1:
=INDEX(A$1:A$9,MATCH(C1,B$1:B$9,0))
 
Upvote 0
Re: Lookup (Index? Match?) First Instance of Condition in Co

I could have promised that I've tried that formula before many times without success, but now I try it again and it works like a champ. Thanks for the assist, Greg.
 
Upvote 0

Forum statistics

Threads
1,215,227
Messages
6,123,739
Members
449,116
Latest member
alexlomt

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