Formula if multiple choices
I have a Countifs formula that I can get to work if a single item is selected from the dropdown but not if both options are selected.
I want to count:
1) Who's affected is Internal (works): =COUNTIFS({ProjectStatus}, "Open", {WhoAffected}, "Internal", {Live}, "Live Input")
2) Who's affected is External (works): =COUNTIFS({ProjectStatus}, "Open", {WhoAffected}, "External", {Live}, "Live Input")
3) Who's affected is BOTH Internal and External - NEED HELP PLEASE.
PS there are only two choices in that dropdown.
Thank you!
Best Answer
-
You'll want to use an OR statement with @cell and CONTAINS:
=COUNTIFS({ProjectStatus}, "Open", {WhoAffected}, OR(CONTAINS("Internal", @cell), CONTAINS("External", @cell)), {Live}, "Live Input")
Regards,
Jeff Reisman
Link: Smartsheet Functions Help Pages Link: Smartsheet Formula Error Messages
If my answer helped solve your issue, please mark it as accepted so that other users can find it later. Thanks!
Answers
-
You'll want to use an OR statement with @cell and CONTAINS:
=COUNTIFS({ProjectStatus}, "Open", {WhoAffected}, OR(CONTAINS("Internal", @cell), CONTAINS("External", @cell)), {Live}, "Live Input")
Regards,
Jeff Reisman
Link: Smartsheet Functions Help Pages Link: Smartsheet Formula Error Messages
If my answer helped solve your issue, please mark it as accepted so that other users can find it later. Thanks!
-
It worked. I used an AND instead of OR but was missing the CONTAINS portion. Appreciate the help.
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 441 Global Discussions
- 139 Industry Talk
- 472 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 496 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!