I have a list of dates in column A (>10,000). I would like to count the number of, say, January 1sts. I tried "=countif(a:a,and(month(a:a)=1,day(a:a)=1))", but it returned a zero. Any ideas?
Thanks
I have a list of dates in column A (>10,000). I would like to count the number of, say, January 1sts. I tried "=countif(a:a,and(month(a:a)=1,day(a:a)=1))", but it returned a zero. Any ideas?
Thanks

This month, every Windows Secrets subscriber can download a one-chapter excerpt of Windows 7: The Missing Manual.Windows 7: The Missing Manual provides valuable information to help you overcome these difficulties in learning a new operating system. Subscribe today to download your free excerpt.
COUNTIF (and SUMIF) don't work with multiple criteria. You must use SUMPRODUCT or array formulas instead, for example:
=SUM((DAY(A1:A20000)=1)*(MONTH(A1:A20000)=1))
entered as an array formula (confirm with Ctrl+Shift+Enter)
Note: you can't use A:A in this formula.
Thanks to Hans and Steve.