COUNTSIFS does not Contain
Hello,
I've put together the following formula, to count certain items in a different sheet that don't meet certain criteria, please see below.
=COUNTIFS({SE-Region}, Region@row, {Status}, <>"Completed", {Status}, <>"Canceled", {Status}, <>"Duplicate", {Summary}, <>CONTAINS("Onboarding", {Summary}))
The formula works until the "{Summary} ("Onboarding", {Summary})), so I'm not sure why this isn't taking.
The answer is outputting "0" to me and the formula is not taking, which I know is not true. Is there anything wrong with my syntax?
Answers
-
Try this...
=COUNTIFS({SE-Region}, Region@row, {Status}, <>"Completed", {Status}, <>"Canceled", {Status}, <>"Duplicate", {Summary}, NOT(CONTAINS("Onboarding", @cell)))
-
Excellent, thank you!
-
Hi @Paul Newcome, having difficulty with a very similar formula, but can't get it to work. Can you please see if there is any syntax that is off here as well?
The formula takes, but the count if 0 for everything I am applying this to.
=COUNTIFS({Carrier}, CONTAINS([Carrier Report Link]@row, {Carrier}), {Status}, <>"Completed", {Status}, <>"Canceled", {Status}, <>"Duplicate", {Summary}, NOT(CONTAINS("Onboarding", {Summary})))
Thank you!
-
You need to use "@cell" references within the range portion of the CONTAINS functions.
-
Hi @Paul Newcome,
I've tried this but still do not get any responses. Is this what you mean?
=COUNTIFS({Carrier}, CONTAINS([Carrier Report Link]@row, {Carrier}), {Status}, <>"Completed", {Status}, <>"Canceled", {Status}, <>"Duplicate", {Summary}, NOT(CONTAINS("Onboarding", @cell)))
-
Yes, but you need that in each of the CONTAINS functions. Your first one still needs the @cell reference.
-
Ah, I see. Perfect, thank you!
-
Happy to help. 👍️
-
Hi @Paul Newcome I'm hoping you can help, I've a similar query…
I am trying to get a count of responses from names in one column ('complainant name', which I've set up successfully as a simple count to this point), to now not include those with a prefix of 'accrued' in the same column. I was trying the above so it was:
=COUNTIF(([Complainant Name]:[Complainant Name]), NOT(CONTAINS("ACCRUED"@CELL))
but I'm getting an unparseable error returned. It's probably something obvious - are you able to help please? Ngā mihi (thanks/regards)
-
@Bek T The parenthesis around the range are not needed. The error itself comes from inside the CONTAINS function though. You need a comma between the two pieces, and "@cell" is case sensitive (needs to be all lower case).
-
Thanks Paul. My brain had got to a point where it went on strike from formulas, haha.
I've done the above and it works, however is now counting blank cells (which wasn't an issue prior to including the not contains). Any thoughts on a simple fix for that one? Cheers -
You could use an AND function to also say "is not equal to blank".
=COUNTIFS([Column Name]:[Column Name], AND(NOT(CONTAINS("text", @cell)), @cell <> ""))
-
Brilliant, thanks Paul, that works (and relieves my brain, not sure why I end up tackling formulas at the end of a busy day, ha!) Ngā mihi
-
Happy to help. 👍️
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 64.2K Get Help
- 419 Global Discussions
- 221 Industry Talk
- 461 Announcements
- 4.8K Ideas & Feature Requests
- 143 Brandfolder
- 142 Just for fun
- 58 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!