Google Sheets – SUMIF Using NOT ISDATE

google sheets

I want to sum across a range of fields, but only if the cell contains a number, not a Date.

I would love to use something like SUMIF(A2:Z2,"!ISDATE()",A2:Z2)

But the criteria in SUMIF is incredibly dumb. Is it possible that there is a valid solution out there?

Best Answer

You can use =SUM(FILTER(A2:Z2,ISERROR(DATEVALUE(A2:Z2)))) where

  • DATEVALUE interprets the content as a date, if it would be auto-converted into a date when entered. Otherwise it throws an error.
  • ISERROR returns True value if its input is an error
  • FILTER narrows down the data set to those columns or rows where the condition holds.