cancel
Showing results for 
Search instead for 
Did you mean: 

8 Hour shift pattern problem

Former Member
0 Kudos

Hi All,

Hope you can help, We have a production facility that operates in 8 hour shift patters (6am to 2pm, 2pm to 10pm, 10pm to 6am). We have a stock report that holds data which is simply Date, Time, Product, Operative
.

We currently run the reports but it's difficult to do the night shift 10pm to 6am, do you have any suggestions on how we can achieve this? Basically we need to see by day by shift

Any suggestions will be helpful.

Thanks

Accepted Solutions (1)

Accepted Solutions (1)

abhilash_kumar
Active Contributor
0 Kudos

Hi Nick,

Easiest way to do this is to use a 'NOT' condition against the other two shifts - that will give you the night shift.

What is the current formula you use for the other shifts?

-Abhilash

ido_millet
Active Contributor
0 Kudos

Change the formula above to:

if ({Start_Time}= Time(22,00,00) and {End_Time} = Time(05,59,59)) Then

{Date_field}-1

Else

{Date_Field}

Or, if there are no start and end times that reflect the shift the record belong to, only time of operation, then

if ({Time} >= Time(22,00,00) and {Time} <= Time(05,59,59)) Then

{Date_field}-1

Else

{Date_Field}

Message was edited by: Ido Millet

Former Member
0 Kudos

Hi Ido,

Thanks for the response I've used

If {WMHistoryDetail.HistMovTimeODBC} In Time (22, 00, 00) to Time (5, 59, 59) then {WMHistoryDetail.HistDateODBC}

Else

{WMHistoryDetail.HistDateODBC}-1

I had to do it that way as the original suggestion was reversing the date results I wanted.

Many thanks for all our help and helping me to learn a new formula.

Answers (1)

Answers (1)

former_member203168
Active Participant
0 Kudos

Hi Nick,

Use below formula to push your third shift date to previous date

if ({Start_Time}= Time(22,00,00) and {End_Time} = Time(05,59,59)) Then

Day({Date_field}-1)

Else

{Date_Field}

Replace date field with above formula in the details section.

--Praveen

Former Member
0 Kudos

Hi Praveen, Thanks for the reply.

I've tried using the formula you've suggested and it says a number is required on my Date_Field

The field is known as a Date field in the database as well.

Any further help?