I am trying to count the number of records for each agent in my table per date range. Example:
5/1/04 - 5/8/04
Agent Records
John 2
Mary 21
Charlie 10
My Code looks like this:
SELECT Leads.Agent, Count(Leads.Agent) AS CountOfAgent
FROM Leads
GROUP BY Leads.Agent
HAVING (((Count(Leads.Agent)) Between [Start Date] And [End Date]));
It is giving me an error that states:
This expression is typed incorrectly, or too complex to be evaluated. For example, a numeric expression may contain too many complicated elements. Try simplifying the expression by assigning parts of the expression to a variables.
Please Help
5/1/04 - 5/8/04
Agent Records
John 2
Mary 21
Charlie 10
My Code looks like this:
SELECT Leads.Agent, Count(Leads.Agent) AS CountOfAgent
FROM Leads
GROUP BY Leads.Agent
HAVING (((Count(Leads.Agent)) Between [Start Date] And [End Date]));
It is giving me an error that states:
This expression is typed incorrectly, or too complex to be evaluated. For example, a numeric expression may contain too many complicated elements. Try simplifying the expression by assigning parts of the expression to a variables.
Please Help