Answered step by step
Verified Expert Solution
Question
1 Approved Answer
CUSTOMER ( primary key = CID ) RENTALS ( primary key = RTN ) In the table RENTALS, RTN provides the rental number ( it
CUSTOMER primary key CID
RENTALS primary key RTN
In the table RENTALS, RTN provides the rental number it is the primary key CID refers to the CID in CUSTOMER, PICKUP is the city where the car was or will be picked up and Return is the city where the car was or will be returned, VIN is a foreign key that references the table CAR. The rental company has two branches, one in San Diego SD and one in Los Angeles LA Cars are picked up and returned by the customers at these two locations.
RENTCOST
In RENTCOST, COST shows the base cost of renting a given MAKE for one day.
CAR
The table CAR primary key VIN provides information about each car, in particular if it is currently rented, and where its usual storage location is attribute AT
CREATE VIEW CUSTSD AS
SELECT FROM CUSTOMER
WHERE Cregion SD
CREATE VIEW CUSTD AS
SELECT CNAME, RENTALS.MAKE, RENTCOST.COST
FROM CUSTOMER, RENTALS, RENTCOST
WHERE CUSTOMER.CID RENTALS.CID
AND RENTALS.MAKE RENTCOST.MAKE
AND RENTCOST
CREATE VIEW MakeView Make NumRentals, Cregion, Storageat AS
SELECT RENTALS.MAKE, Count RTN Cregion, AT
FROM CUSTOMER, RENTALS, CAR
WHERE CUSTOMER.CID RENTALS.CID
AND RENTALS.VIN CAR.VIN
GROUP BY RENTALS.MAKE, Cregion, At
The view MakeView provides the following information:
Group of answer choices
The number of rentals per make
The number of rentals per make and storage place of the car
The number of rentals per make, customer region, and storage place of the car
Each car rented, how often, and where stored
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started