Share via

Shift Classification Designation

Anonymous
2023-11-29T01:15:51+00:00

If I have two shift classifications as below, how would I have excel designate the classification by the shift time entry?

For example

Shift  [255] Shift Start Time  [5] Shift End Time  [5]
Day Shift 6:00 18:00
Day Shift 6:00 18:00
Day Shift 6:00 18:00
Day Shift 6:00 18:00
Day Shift 6:00 18:00
Day Shift 6:00 18:00
Day Shift 6:00 18:00
Night Shift 18:00 6:30
Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

1 answer

Sort by: Most helpful
  1. Anonymous
    2023-11-29T01:58:49+00:00

    Hi Kate,

    Thanks for contacting us,

    To designate the shift classification based on the shift time entry in Excel, you can use the following steps:

    1. **Create a new column:** Insert a new column next to your data to hold the shift classification.
    2. **Use the IF function:** In the first cell of the new column, use the IF function to check if the time falls within the Day Shift or Night Shift. Assuming your Shift Start Time is in cell B2 and Shift End Time is in cell C2, and the time entry is in cell D2, you can use the following formula:
        =IF(OR((D2>=B2)\*(D2<=C2), (d2="">=B2)\*(C2<B2), (D2<B2)\*(C2<B2)), "Day Shift", "Night Shift")
        ```
    
        This formula checks if the time entry (D2) falls within the specified shift time range (B2 to C2) and assigns "Day Shift" if true, otherwise "Night Shift". Make sure to adjust the cell references based on your actual data.
    
    3. \*\*Copy the formula:\*\* Drag the fill handle (a small square at the bottom-right corner of the cell with the formula) down to apply the formula to the entire column.
    
    This formula uses logical conditions to determine whether the time entry falls within the specified shift time range and assigns the appropriate shift classification accordingly. Adjust the cell references based on your actual data and starting cell positions.
    
    I hope this helps!
    
    Regards,
    Sola</=C2),>
    

    Was this answer helpful?

    0 comments No comments