J
John
I am trying to create a formula that will assign a time to
a shift. For example, if my time is 5am and the shift
schedule is:
Shift 1 3am - 11am
Shift 2 11am - 7pm
Shift 3 7pm - 3am
the formula should return "Shift 1".
If the time is 1am, the formula should return "Shift 3".
The caviat is that the shift schedules can change from
week to week. For example, the next week the shifts might
change to:
Shift 1 2am - 10am
Shift 2 10am - 6pm
Shift 3 6pm - 2am
I'm getting stuck on how to handle times that cross into
the next day i.e. say 6pm - 2am.
If anyone has any ideas about how the formula or UDF could
be set up I would appreciate it.
a shift. For example, if my time is 5am and the shift
schedule is:
Shift 1 3am - 11am
Shift 2 11am - 7pm
Shift 3 7pm - 3am
the formula should return "Shift 1".
If the time is 1am, the formula should return "Shift 3".
The caviat is that the shift schedules can change from
week to week. For example, the next week the shifts might
change to:
Shift 1 2am - 10am
Shift 2 10am - 6pm
Shift 3 6pm - 2am
I'm getting stuck on how to handle times that cross into
the next day i.e. say 6pm - 2am.
If anyone has any ideas about how the formula or UDF could
be set up I would appreciate it.