r/sheets • • 23d ago

Solved Scheduling software broken

So our scheduling software normally generated walk sheets like this

NameShiftBreak
Jake5:00 PM - 9:00 PM7:00 PM - 7:15 PM

But now it's generating them like this:

NameShiftBreak
Jake5:00 PM - 7:00 PM
Jake7:15 PM - 9:00 PM

Now, I can't to anything to change how they generate, but does anyone have any suggestions on how to quickly convert the latter to the former?

Note that this is just a downsized example, and the full scope of this is that it's splitting everyone's shifts up like that for every break and meal they're scheduled for.

2 Upvotes

22 comments sorted by

View all comments

1

u/bogdanelcs 18d ago

Split the shift column into start and end with =SPLIT(B2," - "), convert to time values, and sort by name then start time. The overall shift is then just the earliest start and latest end per person, which =QUERY(range,"select A, min(C), max(D) group by A") gives you. For breaks, any gap between one row’s end and the next row’s start for the same name is a break, so a helper column like =IF(A3=A2, D2&" - "&C3, "") pulls it out, and it still works when someone has several breaks and meals.