chubbychap
New member
- Local time
- Today, 18:27
- Joined
- Apr 15, 2008
- Messages
- 3
Hi - newbie here...
I have a project to set up a "simple" room booking database. Basically, rooms are booked, for periods (several days at a time), and I need to be able to query when rooms are free. My main problem is identifying the dates when a room is not booked.
The main booking table is as follows:
Room booking: Booking ID, Room Number, Booking start, Booking end.
So a room might be booked from 1st to 3rd and from 6th to 10th and 17th to 21st, but how do I pull out that it is free on the 4th and 5th and between 11the and 16th. I have tried a number of start date/end date greater than/less than queries, but when using test data I am not getting the results I expect. It all seems so simple on paper.
Any advice greatfully received. Hope I have given enough info.
Chubbychap
I have a project to set up a "simple" room booking database. Basically, rooms are booked, for periods (several days at a time), and I need to be able to query when rooms are free. My main problem is identifying the dates when a room is not booked.
The main booking table is as follows:
Room booking: Booking ID, Room Number, Booking start, Booking end.
So a room might be booked from 1st to 3rd and from 6th to 10th and 17th to 21st, but how do I pull out that it is free on the 4th and 5th and between 11the and 16th. I have tried a number of start date/end date greater than/less than queries, but when using test data I am not getting the results I expect. It all seems so simple on paper.
Any advice greatfully received. Hope I have given enough info.
Chubbychap