lizgraham90
New Member
- Joined
- May 23, 2019
- Messages
- 6
Hi, I hope someone will be able to help me please.
Ok I am trying to work out how long a community centre is open each day. In Column A I have the date, in Column B I have the start time of a booking, in Column C I have the end time of the booking, Column D is the duration of the booking.
I want to calculate total hours each day that the community centre is open, eliminating any double or triple counting if there is any overlap in bookings.
For example in the table below the total hours open on 04/04/2018 would be 6.5 hours.
[TABLE="width: 353"]
<colgroup><col width="104" style="width: 78pt; mso-width-source: userset; mso-width-alt: 3803;"> <col width="126" style="width: 95pt; mso-width-source: userset; mso-width-alt: 4608;"> <col width="108" style="width: 81pt; mso-width-source: userset; mso-width-alt: 3949;"> <col width="132" style="width: 99pt; mso-width-source: userset; mso-width-alt: 4827;"> <tbody>[TR]
[TD="width: 104, bgcolor: transparent"]Date[/TD]
[TD="width: 126, bgcolor: transparent"]Time booking from[/TD]
[TD="width: 108, bgcolor: transparent"]Time booking to[/TD]
[TD="width: 132, bgcolor: transparent"]Duration of booking[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]14:00[/TD]
[TD="bgcolor: transparent"]16:30[/TD]
[TD="bgcolor: transparent"]2.5[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]18:00[/TD]
[TD="bgcolor: transparent"]19:00[/TD]
[TD="bgcolor: transparent"]1[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]19:00[/TD]
[TD="bgcolor: transparent"]21:00[/TD]
[TD="bgcolor: transparent"]2[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]18:00[/TD]
[TD="bgcolor: transparent"]22:00[/TD]
[TD="bgcolor: transparent"]4[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]06/04/2018[/TD]
[TD="bgcolor: transparent"]18:00[/TD]
[TD="bgcolor: transparent"]22:00[/TD]
[TD="bgcolor: transparent"]4[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]07/04/2018[/TD]
[TD="bgcolor: transparent"]09:00[/TD]
[TD="bgcolor: transparent"]11:00[/TD]
[TD="bgcolor: transparent"]2[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]07/04/2018[/TD]
[TD="bgcolor: transparent"]13:00[/TD]
[TD="bgcolor: transparent"]16:00[/TD]
[TD="bgcolor: transparent"]3[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]07/04/2018[/TD]
[TD="bgcolor: transparent"]14:00[/TD]
[TD="bgcolor: transparent"]17:00[/TD]
[TD="bgcolor: transparent"]3[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]09/04/2018[/TD]
[TD="bgcolor: transparent"]09:00[/TD]
[TD="bgcolor: transparent"]14:30[/TD]
[TD="bgcolor: transparent"]5.5[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]09/04/2018[/TD]
[TD="bgcolor: transparent"]12:00[/TD]
[TD="bgcolor: transparent"]13:30[/TD]
[TD="bgcolor: transparent"]1.5[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]09/04/2018[/TD]
[TD="bgcolor: transparent"]14:00[/TD]
[TD="bgcolor: transparent"]15:30[/TD]
[TD="bgcolor: transparent"]1.5[/TD]
[/TR]
</tbody>[/TABLE]
Ok I am trying to work out how long a community centre is open each day. In Column A I have the date, in Column B I have the start time of a booking, in Column C I have the end time of the booking, Column D is the duration of the booking.
I want to calculate total hours each day that the community centre is open, eliminating any double or triple counting if there is any overlap in bookings.
For example in the table below the total hours open on 04/04/2018 would be 6.5 hours.
[TABLE="width: 353"]
<colgroup><col width="104" style="width: 78pt; mso-width-source: userset; mso-width-alt: 3803;"> <col width="126" style="width: 95pt; mso-width-source: userset; mso-width-alt: 4608;"> <col width="108" style="width: 81pt; mso-width-source: userset; mso-width-alt: 3949;"> <col width="132" style="width: 99pt; mso-width-source: userset; mso-width-alt: 4827;"> <tbody>[TR]
[TD="width: 104, bgcolor: transparent"]Date[/TD]
[TD="width: 126, bgcolor: transparent"]Time booking from[/TD]
[TD="width: 108, bgcolor: transparent"]Time booking to[/TD]
[TD="width: 132, bgcolor: transparent"]Duration of booking[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]14:00[/TD]
[TD="bgcolor: transparent"]16:30[/TD]
[TD="bgcolor: transparent"]2.5[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]18:00[/TD]
[TD="bgcolor: transparent"]19:00[/TD]
[TD="bgcolor: transparent"]1[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]19:00[/TD]
[TD="bgcolor: transparent"]21:00[/TD]
[TD="bgcolor: transparent"]2[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]04/04/2018[/TD]
[TD="bgcolor: transparent"]18:00[/TD]
[TD="bgcolor: transparent"]22:00[/TD]
[TD="bgcolor: transparent"]4[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]06/04/2018[/TD]
[TD="bgcolor: transparent"]18:00[/TD]
[TD="bgcolor: transparent"]22:00[/TD]
[TD="bgcolor: transparent"]4[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]07/04/2018[/TD]
[TD="bgcolor: transparent"]09:00[/TD]
[TD="bgcolor: transparent"]11:00[/TD]
[TD="bgcolor: transparent"]2[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]07/04/2018[/TD]
[TD="bgcolor: transparent"]13:00[/TD]
[TD="bgcolor: transparent"]16:00[/TD]
[TD="bgcolor: transparent"]3[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]07/04/2018[/TD]
[TD="bgcolor: transparent"]14:00[/TD]
[TD="bgcolor: transparent"]17:00[/TD]
[TD="bgcolor: transparent"]3[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]09/04/2018[/TD]
[TD="bgcolor: transparent"]09:00[/TD]
[TD="bgcolor: transparent"]14:30[/TD]
[TD="bgcolor: transparent"]5.5[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]09/04/2018[/TD]
[TD="bgcolor: transparent"]12:00[/TD]
[TD="bgcolor: transparent"]13:30[/TD]
[TD="bgcolor: transparent"]1.5[/TD]
[/TR]
[TR]
[TD="bgcolor: transparent"]09/04/2018[/TD]
[TD="bgcolor: transparent"]14:00[/TD]
[TD="bgcolor: transparent"]15:30[/TD]
[TD="bgcolor: transparent"]1.5[/TD]
[/TR]
</tbody>[/TABLE]