How do I calculate an average per hour field in an Access report?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a field that calculates how much time a job took, and a field that
shows how much is being paid for that job. I would like to create a field
that shows the average per hour that was made on that job. I beleive the
problem is that I am trying to divide a currency data type by a time data
type. Is this possible to do.
Thanks for any help, I'm very new at using MS Access. I'm using the 2002
version.
 
As you haven't said what data you have and how you are keeping it, it would
be really difficult to make a suggestion. If your "suspicion" is true, then
that would be a problem.

If you have a start time and an end time for the work, you should be using
the DateDiff function to calculate the actual time worked, and that result
would be in a Single or Double. The Date/Time field or variable is for
recording a point in time, like 05/16/2005 08:49:16, not for recording a
number of hours (you'd want a variable that can have both an integral and
fractional part, like a Single or Double Floating Point, to hold the hours
and fractions thereof).

Larry Linson
Microsoft Access MVP
 
You can divide a currency (which is a number) by a time (which is a number).
If you are using a date/time data type, you need understand that in
date/time values are stored in parts of days. .5 equals 12 hours.
 
Back
Top