Excel if statement with multiple text values in a column

hnew16 - Aug 5, 2017 at 09:30 AM - Latest reply: Mazzaropi 1834 Posts Monday August 16, 2010Registration dateContributorStatus May 30, 2018 Last seen
- Aug 5, 2017 at 10:56 AM
Hello,

I am using excel 2017.

I am trying to use this if statement to give me a value of 1 or 0.

=IF((CQ2="Computer");1;0)

The problem is that in CQ2, I sometimes have a list of text values, such as "Television;Computer;Phone" or "Computer;Phone" or "Newspaper;Television;Computer;Phone".

This was exported from Google drive survey.

How can I make it so it inputs a value of 1 if the word Computer is present and if not a 0?



See more 

Your reply

1 reply

Mazzaropi 1834 Posts Monday August 16, 2010Registration dateContributorStatus May 30, 2018 Last seen - Aug 5, 2017 at 10:56 AM
0
Thank you
hnew16, Good morning.

Try to use:

=IF(ISNUMBER(SEARCH("computer",CQ2)),1,0)

Please tell us if it worked as you desire.
Respond to Mazzaropi