#incorrect argument for COUNTIFS and ISDATE/checking DATA exists
I am trying to use a COUNTIFS statement that looks at a Sheet and counts rows that contain a Column with specific text (Names, first and last) and a column that is a Date. I'm writing this formula in its own sheet. The sheet contains a list of 70 names and my formula will use that cell to reference that in the first IF statement. I have that working. When I add the second statement, to look for a DATE in the column I get the "#Incorrect Argument" error. Any suggestions would be appreciated.
Formulas I have tried are:
=COUNTIFS({Range 1}, =[Primary Column]@row, {Range 2}, @cell <> "")
=COUNTIFS({Range 1}, =[Primary Column]@row, {Range 2}, ISDATE(@cell) = 1)
Answers
-
Hi @Miami_Fins, to troubleshoot I would strip Range 1 out of the COUNTIFS to make sure you can count your dates. Also, is the Date Range 2 column a "Date" column type? If not, then the "ISDATE" will return an error.
I often use a "LEN" function when I'm trying to check if a cell has any content. It's kind of bulletproof in its ability to detect content in a cell, and works whether the column has a column formula or not (which is not always true for <>"").
Try the below -- I removed the equals from in front of the Primary Column reference as it's not required. Also, obviously, doublecheck to make sure that Range 2 is pointing at the correct column.
=COUNTIFS({Range 1}, [Primary Column]@row, {Range 2}, LEN(@cell)>0)
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 65.2K Get Help
- 445 Global Discussions
- 143 Industry Talk
- 476 Announcements
- 5K Ideas & Feature Requests
- 84 Brandfolder
- 150 Just for fun
- 71 Community Job Board
- 488 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 301 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!