M
Mark
Hello all,
I need to run an automated query based on shift. There is nothing in the
table showing shift, so I will have to use the time stamp. The query will
also have a date range selection.
What is the best way to determine what shift it is based on the date and
time stamp? Would it be best to have a table setup with the Shift, Start
Time, End Time, and Day then compare the timestamp to this table?
Example:
Date/time stamp. How could I find what shift this was associated with?
07/04/06 06:04:01
If I have a table with the shift, Start Time, End Time, Day how would I
determine if the previous time stamp falls within its range since I have 2
field, one with start and one with end?
Table
Shift Start Time End Time Day
A 06:00 17:59 Monday
A 06:00 17:59 Tuesday
Would it be better to have a table like this and just use the hour and day
part of time?
Shift time Day
A 06 Monday
A 07 Monday
A 08 Monday
A 09 Monday
A 10 Monday
A 11 Monday
A 12 Monday
A 13 Monday
A 14 Monday
A 15 Monday
Or, is there a better way?
Thanks!
I need to run an automated query based on shift. There is nothing in the
table showing shift, so I will have to use the time stamp. The query will
also have a date range selection.
What is the best way to determine what shift it is based on the date and
time stamp? Would it be best to have a table setup with the Shift, Start
Time, End Time, and Day then compare the timestamp to this table?
Example:
Date/time stamp. How could I find what shift this was associated with?
07/04/06 06:04:01
If I have a table with the shift, Start Time, End Time, Day how would I
determine if the previous time stamp falls within its range since I have 2
field, one with start and one with end?
Table
Shift Start Time End Time Day
A 06:00 17:59 Monday
A 06:00 17:59 Tuesday
Would it be better to have a table like this and just use the hour and day
part of time?
Shift time Day
A 06 Monday
A 07 Monday
A 08 Monday
A 09 Monday
A 10 Monday
A 11 Monday
A 12 Monday
A 13 Monday
A 14 Monday
A 15 Monday
Or, is there a better way?
Thanks!