By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,052 Members | 1,551 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,052 IT Pros & Developers. It's quick & easy.

Time calculations in Access 2000

P: n/a

I am trying to create a database that involves time calculation (elapsed
time). I have set up several tables and one is for "Time Card" entry. I
cannot figure out how to calculate the elapsed time between Start Time
and End Time in Query.

Please help this is for my boss.
--
Posted via http://dbforums.com
Nov 12 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
The Datadiff function will do some of the work for you.

x = Datediff("s",starttime, endtime) will give the difference in seconds.
You can then do the divisions to get hours , mins and secs.

e.g x mod 60 gives you the number of secs
x\60 gives the total number of minutes
etc

But to do this in a query would give some unmanageable expressions, so you
are better off creating a function to do it.

Regards

Peter Russell
Arargorn previously wrote:

I am trying to create a database that involves time calculation (elapsed
time). I have set up several tables and one is for "Time Card" entry. I
cannot figure out how to calculate the elapsed time between Start Time
and End Time in Query.

Please help this is for my boss.
--
Posted via http://dbforums.com


Nov 12 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.