Excel formula to check for info in first of four columns.

Jill DT 20 Reputation points
2026-06-02T13:24:40.2566667+00:00

Hello and thank you for any help you can provide.

I have a spreadsheet with 5 columns I want to analyze using a formula.

The cells may or may not contain data.

I am looking for a specific value(Joe), but I only want a Yes response if my value (Joe) is the first value to appear.

For instance:

If the values are Steve / Joe / Allan / Bill / Bob. Since Joe appears second (or anything but first), I want a "No".

If the values are Blank / Blank / Joe / Steve / Blank (or any order where Joe is the first non-blank value) I want a "Yes".

I hope this is clear.

Thanks,

Jill

Microsoft 365 and Office | Excel | For business | Windows
0 comments No comments

Answer accepted by question author
Rory Archibald 19,140 Reputation points Volunteer Moderator
2026-06-02T14:29:34.7933333+00:00

You could use something like:

=IF(XLOOKUP("*",B1:F1,B1:F1,"",2)="Joe","Yes","No")

Was this answer helpful?

1 person found this answer helpful.

0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.