COUNTIF with date range and another critieria
Hi,
I'm trying to count the number of rows which have a 60-day opt-out window between x and y and where the "Monthly DataCor Revenue" is blank.
This formula works (y'all helped me with this):
=COUNTIFS({Lite 60 day opt out}, AND(@cell >= DATE(2022, 8, 1), @cell <= DATE(2022, 8, 31)))
but I cannot get an answer when I add in the "Monthly DataCor Revenue" is blank criteria. This is what I've been working with but I get Invalid Data Type:
=COUNTIFS(AND({Monthly DataCor Revenue}, "", ""), {Lite 60 day opt out}, AND(@cell >= DATE(2022, 4, 1), @cell <= DATE(2022, 4, 30)))
I also tried this, same error:
=COUNTIFS({Lite 60 day opt out}, AND({Monthly DataCor Revenue}, "", "", @cell >= DATE(2022, 4, 1), @cell <= DATE(2022, 4, 30)))
Any ideas? Thanks!!
Best Answer
-
You don't need the additional AND (or its corresponding parenthesis).
=COUNTIFS({Monthly DataCor Revenue}, @cell = "", {Lite 60 day opt out}, AND(@cell >= DATE(2022, 4, 1), @cell <= DATE(2022, 4, 30)))
Answers
-
You don't need the additional AND (or its corresponding parenthesis).
=COUNTIFS({Monthly DataCor Revenue}, @cell = "", {Lite 60 day opt out}, AND(@cell >= DATE(2022, 4, 1), @cell <= DATE(2022, 4, 30)))
-
Thanks Paul!
-
Happy to help. 👍️
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Customer Resources
- 64.9K Get Help
- 439 Global Discussions
- 138 Industry Talk
- 471 Announcements
- 4.9K Ideas & Feature Requests
- 129 Brandfolder
- 148 Just for fun
- 68 Community Job Board
- 486 Show & Tell
- 33 Member Spotlight
- 2 SmartStories
- 300 Events
- 36 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!