Question: Write the SQL QUERY to: a. List the number of bookings and the average booked price of all cottages in Halifax. b. List the names

 Write the SQL QUERY to: a. List the number of bookings

Write the SQL QUERY to:

a. List the number of bookings and the average booked price of all cottages in Halifax.

b. List the names of all regions with the average, minimum and maximum price of their booked cottages (Regions with no cottages booked are excluded)

c. All bookings for Tourista are done through a website that charges a commission of 5% of the booked price. How much money does Tourista owe to that website for each cottage in total. List the cottage name with the total booking price and the websites commission.

Cottage Cottage_ID INT Cottage Name VARCHAR(45) Cottage-Num Rooms INT Region_Code INT | Cottage-Facility CF Num INT Region Region_Code INT Region Name VARCHAR(45) Facility_ID INT Cottage. ID INT Indexes Indexes Indexes Customer Facility Facility_ID INT Booking Booking_ID INT Booking. Date DATE Booking-Price INT Customer_ID INT Cottage-ID INT Customer ID INT Customer LName VARCHAR(45) Customer-FName VARCHAR(45) Customer. MInitial VARCHAR(5) Customer-Email VARCHAR(45) Customer-Phone VARCHAR(15) Facility-Name VARCHAR(45) Facility-IsShared BOOLEAN Indexes Indexes Indexes

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 Databases Questions!