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
- 67.1K Get Help
- 449 Global Discussions
- 155 Industry Talk
- 505 Announcements
- 5.4K Ideas & Feature Requests
- 85 Brandfolder
- 156 Just for fun
- 80 Community Job Board
- 514 Show & Tell
- 34 Member Spotlight
- 2 SmartStories
- 308 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!