Nested IF with CONTAINS
I'm trying to return a value based on different comparisons of the same string.
Example:
Return SIL, BRZ or GLD if one of those terms are in this string : "[blah1_SIL_L01_C99A] blahserver"
What works: =IF(CONTAINS("SIL", Path4), "SIL")
What doesn't work:
=IF(OR(CONTAINS("BRZ", Path4), "BRZ"), IF(CONTAINS("SIL",Path4), "SIL"))
=IF((CONTAINS("BRZ", Path4), "BRZ"), IF(CONTAINS("SIL", Path4), "SIL"))
Path4 refers to the cell containing the string "[blah1_SIL_L01_C99A] blahserver"
I have thousands of rows to perform this on.
Thanks!
Andrea
Best Answer
-
=IF(CONTAINS("BRZ", Path4), "BRZ", IF(CONTAINS("SIL", Path4), "SIL"
Just some parenthesis issues with your second solution
Answers
-
=IF(CONTAINS("BRZ", Path4), "BRZ", IF(CONTAINS("SIL", Path4), "SIL"
Just some parenthesis issues with your second solution
-
That worked! Thanks so much for the quick answer!!
-
NP glad I could help
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.8K Get Help
- 434 Global Discussions
- 138 Industry Talk
- 470 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 65 Community Job Board
- 486 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!