IF with OR Function using wildcard characters

danb2000

New Member
Joined
Jun 18, 2015
Messages
2
Hello

I can find thread explaining how to use wildcard characters with IF using COUNTIF but I am trying to find something that will search multiple columns to say "Y" or "N" if it is contained in either cell.

=IF((OR(A1="dealing", AB1="dealing")), "Y", "N")

The above formula would do this if I specified the whole word or the cell only contain the word "dealing" but I need it to do the same but with wildcard characters and I know they don't work with straight IF functions.

So.... I want it to say "Y" if the word 'dealing' anywhere in either cell and "N" if it does not.

Hope this is clear. Any ideas? Thanks in advance.
 

Excel Facts

What is =ROMAN(40) in Excel?
The Roman numeral for 40 is XL. Bill "MrExcel" Jelen's 40th book was called MrExcel XL.
This formula should do what you want...

=IF(ISNUMBER(SEARCH("dealing",A1&" "&AB1)),"Y","N")
 
Upvote 0
Rick has a good, succinct formula that should work for you.

Here's an option that uses the COUNTIF function and wild cards...just so you can see how it works:

=IF(OR(COUNTIF(A1,"*dealing*"),COUNTIF( AB1,"*dealing*")), "Y", "N")
 
Upvote 0

Forum statistics

Threads
1,223,243
Messages
6,170,971
Members
452,371
Latest member
Frana

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