In a row are columns with some attributes. The row includes a column start, end with a time in HH:MM format. I want to have for each full hour one row, excluding the end hour
e.g.
Attr 1, start, end
row0: value0, 14:00, 16:00
row1: value1, 15:00, 16:00
the result should be:
Attr 1, start, end, hour
row0: value0, 14:00, 16:00, 14:00
row1: value0, 14:00, 16:00, 15:00
row2: value1, 15:00, 16:00, 15:00
It calcs the difference between the times, adds in additional rows, then determines an “hour offset” starting at 0 for the first row, and creates a new column based on that offset from the start hour.
There are no dates, so I don’t know what you intended to do if the start and end time crossed the midnight boundary . Likewise, I don’t know what should happen if the time isn’t exactly on the hour, but hopefully this gives some ideas that you can build on.