need to get totals on a querey...

Carrie

Active Member
Joined
Nov 20, 2002
Messages
418
Is there a way for me to get the total # of calls closed and the total event time for each tech?

Here is the SQL...

SELECT Event.AddUser, Call.IsClosed, Event.EventTime, Event.AddDate
FROM Event INNER JOIN Call ON Event.Call_ID = Call.Call_ID
WHERE (((Event.AddDate)>=[Start Date] And (Event.AddDate)<=[End Date]))
ORDER BY Event.AddUser;

I think it may need a sub querey or something.

For those of you that don't know me...I am a novice when it comes to access but I am slowly learning.
 

Excel Facts

Copy a format multiple times
Select a formatted range. Double-click the Format Painter (left side of Home tab). You can paste formatting multiple times. Esc to stop
Not sure if this is what you are after but give this a go.

SELECT Count(Call.IsClosed) AS CountOfIsClosed, Sum(Event.EventTime) AS SumOfEventTime, Call.ClosedBy, Call.IsClosed
FROM Event INNER JOIN Call ON Event.call_id = Call.call_id
WHERE (((Event.AddDate)>=[Start Date] And (Event.AddDate)<=[End Date]))
GROUP BY Call.ClosedBy, Call.IsClosed
HAVING (((Call.IsClosed)=True));

Having to guess on some fields in tables, so added Call.ClosedBy

Hope this helps?
 
Upvote 0

Forum statistics

Threads
1,221,510
Messages
6,160,226
Members
451,632
Latest member
purpleflower26

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top