Forum Discussion
Maria_Garcia_MEGA
Jun 22, 2022Copper Contributor
Formula to find a string
Hello!
I'm struggling with something that seems simple. I'm trying to wrote a formula that looks for a specific string in a cell: "Appointment of Rep". The cell can contain many things, below are a few examples. I've tried many things but none of them work, any thoughts or ideas!!
Some of the values in the cells, I want to return TRUE if any of the below contain "Appointment of Rep" and FALSE if it does not.
Appointment of Rep
Benefits, Tardiness, Appointment of Rep
Benefits, Appointment of Rep, Tardiness
Benefits, Tardiness
Tardiness, Benefits
Thank you for your help in advance!!
5 Replies
Sort By
- Subodh_Tiwari_sktneerSilver Contributor
Assuming your string is in cell A2, then you may try one of the below formulas...
=IF(ISNUMBER(SEARCH("Appointment of Rep",A2)),"True","False")
OR
=IF(ISNUMBER(FIND("Appointment of Rep",A2)),"True","False")
OR
=IF(COUNTIF(A2,"*Appointment of Rep*"),"True","False")
- Maria_Garcia_MEGACopper Contributor
Subodh_Tiwari_sktneer Thank you so much! Those were all of the formulas I had tried and they didn't work, they all returned FALSE. I even tried those formulas with "*" in between the words as a wild card and it didn't help either.
- Subodh_Tiwari_sktneerSilver Contributor
It would be better if you upload a sample workbook with formulas in place to find the issue with the formulas.