Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Conv time so I can get an Average

1 view
Skip to first unread message

Leon

unread,
Mar 3, 2003, 4:34:29 AM3/3/03
to
I need to get the ave of time expl: 10:00, 1:00 9:00
Ave is 6.667 how can I do this in Access
All help will be greatly apreciated

John Nurick

unread,
Mar 3, 2003, 4:09:56 PM3/3/03
to
Hi Leon,

If the times are stored in an Access date/time field - I'll
call it "TimeField" - beneath the surface they are just numbers
in the range 0 (midnight) to nearly 1 (23:59:59.9999 or
thereabouts).

To get the average as decimal hours, use a calculated field in
a Totals query, like this
AvgTime: Avg(CDbl([TimeField])*24)

Or to get it as a string showing hours, minutes and seconds use
something like this:
AvgTime: Format([TimeField], "hh:nn:ss")

John Nurick [Microsoft Access MVP]

Please respond in the newgroup and not by email.

0 new messages