|
Question : Reservation Database, need help with organization, etc.
|
|
Okay, here goes. I am very new to database design but I have learned a lot in a short period of time. I have a very complicated database hence, I have found some complicated problems.
This database will be used as a basic hotel management program. Unlike a normal hotel however, we host conferences where one attendee may have 100 people in their group with only one attendee name so id attributes must be assigned to distinguish the guests from one another, I am using a count method to insure no double booking occurs (count # of guests=# of assigned guests). It is also a resource management and accounting program. Whew!
I have built numerous tables/forms.
-Attendee -Registration(attendees may attend more than one event) -Events -Resources (rooms, etc. about 4300 iems) -Reservations-by assigning individual reservation numbers to each member of an attendee group -Account -Payments and many, many more:)
MY PROBLEM:
-How do I set up my tables and queries to find available resources. (pretty much have this figured out, I think) -How to design a table/form with combo boxes or list boxes using a query of available resources to make new reservations. (The query is already functioning). -So, mainly I am looking for advice on the form/table for reservations.
Mine currently looks like this:
RESERVATIONS Reservation ID (primary key) Registration ID Attendee ID Guest Type ID (male, female) Event ID FeeScheduleID ResourceType ID Resource Name (an id number for each room other than room number because there is more than one building used so there are two fields in the actual room name. The data is uploaded this way. It would be too time consuming to combine Hall name and Room number into one field.)
Then a button on the buttom to see the query results for available roooms.
Currently, you must check the query results form (Available Rooms) (displayed by button, and same info in combo box on the Reservations Form) to find the desired resource and check the occupied checkbox to mean yes. Then, you must find the matching resource on the reservation form by using the resource id number and select it from the combo box.
As I re-read this, it doesn't seem extremely clear. I would appreciate any good advice. If you need more information, I will try to be more clear. Thanks!
|
|
Answer : Reservation Database, need help with organization, etc.
|
|
<< But.. would this work? How do I go about writing a query that would do this? How would I execute? >>
Yes, that would work and is easier then you think. The 2nd combo's rowsource would be based on a query that does two things:
1. Get's the available rooms (not down for maintenance) 2. Of the available rooms, which do not have reservations for the time period requested?
This is done by using an Outer Join in the query designer. I have a small sample database I can send you which demos this. Post and e-mail address or send a message to me and I'll send it along.
The setup then would be to have the 1st combo requery the 2nd combo in it's AfterUpdate event. The above query would then be executed and the list of rooms displayed.
Jim.
|
|
|
|