IF OR Formula
I'm trying to come up with a formula that if the user selects either one choice or multiple choices in the same category it will equal the same or highest amount.
For instance:
Dog, cat = 3
Mouse, rat = 2
Snake, lizard = 1
If a user selects dog it needs to equal 3. However, if a user chooses dog and cat it also equals 3. The last example is if a user selects dog and lizard it will equal the highest amount of 3.
Having problems coming up with a formula for this. Any help on this would be greatly appreciated.
Answers
-
Hi @KCope21,
Your formula would look like this:
=IF(OR(HAS([Animal dropdown]@row, "Dog"), HAS([Animal dropdown]@row, "Cat")), 3, IF(OR(HAS([Animal dropdown]@row, "Mouse"), HAS([Animal dropdown]@row, "Rat")), 2, IF(OR(HAS([Animal dropdown]@row, "Snake"), HAS([Animal dropdown]@row, "Lizard")), 1)))
Sample data/output:
Hope this helps, but if you've any problems/questions then just let us know!
-
=IF(OR(
CONTAINS("cat", Animal@row),
CONTAINS("dog", Animal@row)), 3, IF(OR(
CONTAINS("mouse", Animal@row),
CONTAINS("rat", Animal@row)), 2, IF(OR(
CONTAINS("lizard", Animal@row),
CONTAINS("snake", Animal@row)), 1, "")...
-
Tried this and its coming back as unparseable.
-
Also tried this one and its coming back as unparseable.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 64.3K Get Help
- 423 Global Discussions
- 221 Industry Talk
- 461 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 143 Just for fun
- 59 Community Job Board
- 462 Show & Tell
- 32 Member Spotlight
- 1 SmartStories
- 300 Events
- 39 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!