I'm developing a system which is used for calculation of employees hours worked and rates of pay. I currently have a query which is calculating the hours worked between a [StartTime] and [EndTime] primarily using the DateDiff function.
This works great most of the time however on some occasions employees are working nightshifts for example 19:00 - 7:00 the following day. Therefore my [HoursActive] field is displaying -12 and my [PayAmount] field is showing -£60.00 (based on a £5 per hour rate variable).
There may be a simple solution but i simply want the system to work these out as normal hours and not negatives so there are no negatives in the system. But the same section must work for normal hours on the same day and those overlapping over a 00:00 time slot. I hope someone can help!
J
This works great most of the time however on some occasions employees are working nightshifts for example 19:00 - 7:00 the following day. Therefore my [HoursActive] field is displaying -12 and my [PayAmount] field is showing -£60.00 (based on a £5 per hour rate variable).
There may be a simple solution but i simply want the system to work these out as normal hours and not negatives so there are no negatives in the system. But the same section must work for normal hours on the same day and those overlapping over a 00:00 time slot. I hope someone can help!
J