COUNTIF with OR

atewari1
atewari1 ✭✭
edited 02/22/24 in Formulas and Functions

I am trying to count all instances of a name where the corresponding status is Open or Tracking.

My formula is =COUNTIFS({Coordination Log - Autumn Willow Range 1}, "Chris Rush", {Coordination Log - Autumn Willow Range 2}, OR(@cell = "Open", @cell = "Tracking"))

In the last portion where the OR comes into play, I initially tried having the range {Coordination Log - Autumn Willow Range 2} = to "Open" and "Tracking" but that yielded #INVALID OPERATION.

My current fomula should output a value of 4, but I am getting 0. Is this perhaps a syntax error where I have @cell = "Open"/"Tracking" ?


NOTE: I am trying to count the name within a multi-select contact column. Will I need to use a COUNTM?

Best Answer

  • Leibel S
    Leibel S ✭✭✭✭✭✭
    Answer ✓

    @atewari1

    You need to use the HAS function to check if the column has the name Chris Rush:

    =COUNTIFS({Coordination Log - Autumn Willow Range 1}, HAS(@cell, "Chris Rush"), {Coordination Log - Autumn Willow Range 2}, OR(@cell = "Open", @cell = "Tracking"))

Answers

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!