COUNTIF with AND function
Hi there,
I'm trying to count the instances that a contract has been executed and occurred in the year 2020. The formula I have unfortunately returns as "incorrect argument set". Any help would be greatly appreciated.
=COUNTIF([Status of Contract]:[Status of Contract], "Executed", AND([Date Received]:[Date Received], IFERROR(YEAR(@cell), 0) = 2020))
Best Answer
-
When dealing with multiple criteria, you need to use COUNTIFS (plural) instead of COUNTIF (singular). As a point of note, COUNTIFS (plural) can always be used, regardless if one criteria or many. Note that the criteria within the COUNTIFS are already 'AND' criteria
=COUNTIFS([Status of Contract]:[Status of Contract], "Executed", [Date Received]:[Date Received], IFERROR(YEAR(@cell), 0) = 2020)
cheers,
Kelly
Answers
-
When dealing with multiple criteria, you need to use COUNTIFS (plural) instead of COUNTIF (singular). As a point of note, COUNTIFS (plural) can always be used, regardless if one criteria or many. Note that the criteria within the COUNTIFS are already 'AND' criteria
=COUNTIFS([Status of Contract]:[Status of Contract], "Executed", [Date Received]:[Date Received], IFERROR(YEAR(@cell), 0) = 2020)
cheers,
Kelly
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!