So, I'm trying to count of the number of occurrences of text that happen between two dates among multiple sheets in a workbook, and I cannot get the correct number. I have dates in the E column of each worksheet, and the text I want to count is in column F. For the dates I want to limit, I have them in cells E5 and E6 on the same sheet as the formulas. I currently have the E5/E6 cells dated 01-01-05 and 28-05-13 (there are no dates that go back to 2005, I'm doing this to test the formulas for accurate results before I start limiting).
If I use a COUNTIF, it returns 15. (expected)
=COUNTIF(Sheet2!$F:$F,text)
If I try to use a COUNTIFS to limit the date, it returns 0 even if I don't put the end date.
=COUNTIFS(Sheet2!$F:$F,text,Sheet2!$E:$E,">="&$E$5)
If I try a SUMPRODUCT from the start date, it returns the expected number if I don't put the end date. Which will return 0 if I do.
=SUMPRODUCT((Sheet2!$F$3:$F$100 = text)*(Sheet2!$E3:$E$100 >= $E$5))-SUMPRODUCT((Sheet2!$F$3:$F$100 = text)*(Sheet2!$E3:$E$100 > $E$6))
Is there something I'm missing that would cause both the COUNTIFS and SUMPRODUCT functions to return incorrect values? Any help is appreciated, thanks!
Bookmarks