Question: I have database design for hotel managemnet system with the following requirements : 1 . Guest can do many bookings ( 1 to M )

I have database design for hotel managemnet system with the following requirements :1. Guest can do many bookings (1 to M) relationship.
2. Booking can have many rooms and the room can be booked many time so it is a (M to M ) relationship.
3. Floor have many rooms (1 to M ) relationship.
4. A room has one class but a class can be related to many rooms so it is a (1 to M) relationship.
5. A room class can have many features and the feature can belong to many classes so it is a (M to M) relationship.
6. A class of room can have many beds and a bed type can belong to different room classes, so (M to M) relationship.
7. A booking can have many addons, and an addon can be related to many bookings so (M to M) relationship.
8. A booking can have payment status and the payment status can belong to many bookings so (1 to M) relationship.
9. A room has a room status and the room status can be related to many rooms so (1 to M) relationship. the entities and attributes are : 1. GUEST has attributes: id(key),first_name,last_name,phone_number,email_address .
2. BOOKING has attributes: id(key),checkin_date,checkout_date,num_adults,num_children, booking_amount.
3. ROOM_CLASS has attributes:id(key),class_name,base_price.
4. ROOM has attributes: id(key),room_number.
5. FEATURE has attributes: id(key),feature_name.
6. FLOOR has attributes: id(key),floor_number .
7. ADDON has attributes: id(key),addon_name,price.
8. BED_TYPE has attributes: id(key),bed_type_name.
9. PAYMENT_STATUS has attributes: id(key),payment_status_name.
10. ROOM_STATUS has attributes: id(key),status_name. The questions is : 1. create a set of complex SQL queries to extract insights and perform tasks as described above.
2. create a document describing the insights and results obtained from the SQL queries and any recommendations based on the findings

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!