# CountIF between date range with Multiple Criteria

Hi Experts,

I have a workbook where I need to count the number of Interactions between a date range based on an employees name and wanted to know if this can be done?

Attached is a sample workbook with the following formula

=SUMPRODUCT((RLOFTracker[Date Worked]>=\$F\$1)*(RLOFTracker[Date Worked]<=\$G\$1)*(RLOFTracker[CQ Agent]=A2)*(RLOFTracker[Interaction ID]))

Col A has the Employee Names, Col B is where I have the above formula, Col F & G holds the dates.

I have a table that's holding the Interactions each employee had on a specified date.  I need to count the number of Interactions an Employee had between a date range
EE-CountIF-Multiple-Criteria.xlsx
###### Who is Participating?

x

Commented:
Hi,
If you would like to count, you do not need the number of interactions:

=SUMPRODUCT((RLOFTracker[Date Worked]>=\$F\$1)*(RLOFTracker[Date Worked]<=\$G\$1)*(RLOFTracker[CQ Agent]=A2))

or if you are not sure the ID is filled or not:
=SUMPRODUCT((RLOFTracker[Date Worked]>=\$F\$1)*(RLOFTracker[Date Worked]<=\$G\$1)*(RLOFTracker[CQ Agent]=A2)*(RLOFTracker[Interaction ID]<>""))

Cheers,
Kris
``````=SUMPRODUCT((RLOFTracker[Date Worked]>=\$F\$1)*(RLOFTracker[Date Worked]<=\$G\$1)*(RLOFTracker[CQ Agent]=A2))
``````
0

Commented:
Is the attached what you were looking for: Using COUNTIFS

=COUNTIFS(RLOFTracker[CQ Agent],Sheet1!A2,RLOFTracker[Date Worked],">="&Sheet1!\$F\$1,RLOFTracker[Date Worked],"<="&Sheet1!\$G\$1)
EE-CountIF-Multiple-Criteria.xlsx
0

self employedAuthor Commented:
Works great!  Thank you leptonka
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.