Query For Average Days

  • Thread starter christy via AccessMonster.com
  • Start date
C

christy via AccessMonster.com

I have a query that counts the number of days between start and completed.
This may be a difference of 1 or more days. Below is my query. How can I
group this to give me an average of days per branch?

SELECT [qryFILLED - AT].LOB_NAME, [qryFILLED - AT].DistName, [qryFILLED - AT].
Region, [qryFILLED - AT].ZoneName, [qryFILLED - AT].ENTEREDDATE, [qryFILLED -
AT].CompletedDate, DateDiff("d",[ENTEREDDATE],[CompletedDate]) AS DaysToFill
FROM [qryFILLED - AT];

Thanks,
Christy
 
K

KARL DEWEY

Did not know whether YOUR_BRANCH was Region OR ZoneName.

SELECT [qryFILLED - AT].YOUR_BRANCH,
Avg(DateDiff("d",[ENTEREDDATE],[CompletedDate]) AS AvgDaysToFill
FROM [qryFILLED - AT]
GROUP BY [qryFILLED - AT].YOUR_BRANCH;
 
Top