Examlex

Solved

Figuer:
CUSTOMER In Table CUSTOMER, CID Is the Primary Key (Customer ID)

question 32

Multiple Choice

Figuer:
CUSTOMER  CID  CNAME  AGE  RESID_CITY  BIRTHPLACE 10 BLACK 40 ERIE  TAMPA 20 GREEN 25 CARY  ERIE 30 JONES 30 HEMET  TAMPA 40 MARTIN 35 HEMET  TAMPA 50 SIMON 22 ERIE  ERIE 60 VERNON 60 CARY  CARY \begin{array} { | l | l | l | l | l | } \hline \text { CID } & \text { CNAME } & \text { AGE } & \text { RESID\_CITY } & \text { BIRTHPLACE } \\\hline 10 & \text { BLACK } & 40 & \text { ERIE } & \text { TAMPA } \\\hline 20 & \text { GREEN } & 25 & \text { CARY } & \text { ERIE } \\\hline 30 & \text { JONES } & 30 & \text { HEMET } & \text { TAMPA } \\\hline 40 & \text { MARTIN } & 35 & \text { HEMET } & \text { TAMPA } \\\hline 50 & \text { SIMON } & 22 & \text { ERIE } & \text { ERIE } \\\hline 60 & \text { VERNON } & 60 & \text { CARY } & \text { CARY } \\\hline\end{array} In table CUSTOMER, CID is the primary key (Customer ID) .
RENTALS  CID  MAKE  DATE_OUT  PICKUP  RETURN  RTN 10 FORD 100ct1994 CARY  CARY 110 GM 01Nov1995 TAMPA  CARY 210 FORD 01Jan1995 ERIE  ERIE 320 NISSAN 07Ju11994 TAMPA  TAMPA 430 FORD 01Jul1995 CARY  ERIE 530 GM 01Aug1995 ERIE  ERIE 640 FORD 01Aug1994 CARY  ERIE 750 GM 01Sep1995 ERIE  CARY 870 TOYOTA 02Sep1995 RENO  RENO 9\begin{array} { | l | l | l | l | l | l | } \hline \text { CID } & \text { MAKE } & \text { DATE\_OUT } & \text { PICKUP } & \text { RETURN } & \text { RTN } \\\hline 10 & \text { FORD } & 10 - 0 c t - 1994 & \text { CARY } & \text { CARY } & 1 \\\hline 10 & \text { GM } & 01 - N o v - 1995 & \text { TAMPA } & \text { CARY } & 2 \\\hline 10 & \text { FORD } & 01 - J a n - 1995 & \text { ERIE } & \text { ERIE } & 3 \\\hline 20 & \text { NISSAN } & 07 - J u 1 - 1994 & \text { TAMPA } & \text { TAMPA } & 4 \\\hline 30 & \text { FORD } & 01 - J u l - 1995 & \text { CARY } & \text { ERIE } & 5 \\\hline 30 & \text { GM } & 01 - A u g - 1995 & \text { ERIE } & \text { ERIE } & 6 \\\hline 40 & \text { FORD } & 01 - A u g - 1994 & \text { CARY } & \text { ERIE } & 7 \\\hline 50 & \text { GM } & 01 - S e p - 19 95 & \text { ERIE } & \text { CARY } & 8 \\\hline 70 & \text { TOYOTA } & 02 - S e p - 1995 & \text { RENO } & \text { RENO } & 9 \\\hline\end{array} In the table RENTALS, RTN provides the rental number (the primary key) , CID is the customer's unique id, PICKUP is the city where the car was picked up, and Return is the city where the car was returned.
RENTCOST  MAKE  COST  FORD 30 GM 40 NISSAN 30 TOYOTA 20 VOLVO 50\begin{array} { | l | l | } \hline \text { MAKE } & \text { COST } \\\hline \text { FORD } & 30 \\\hline \text { GM } & 40 \\\hline \text { NISSAN } & 30 \\\hline \text { TOYOTA } & 20 \\\hline \text { VOLVO } & 50 \\\hline\end{array} RENTCOST shows the base cost of renting a given MAKE for one day.
CITYADJ  CITY  FACTOR  CARY 1 ERIE 1.1 RENO 0.9 TAMPA 0.8\begin{array} { | l | l | } \hline \text { CITY } & \text { FACTOR } \\\hline \text { CARY } & 1 \\\hline \text { ERIE } & 1.1 \\\hline \text { RENO } & 0.9 \\\hline \text { TAMPA } & 0.8 \\\hline\end{array} If the return city of table RENTALS is the one listed in table CITYADJ, the cost of the rental is multiplied by FACTOR and by DAYS shown in table RENTLENGTH below.
RENTLENGTH  RTN  DAYS 1123324254627381\begin{array} { | l | l | } \hline \text { RTN } & \text { DAYS } \\\hline 1 & 1 \\\hline 2 & 3 \\\hline 3 & 2 \\\hline 4 & 2 \\\hline 5 & 4 \\\hline 6 & 2 \\\hline 7 & 3 \\\hline 8 & 1 \\\hline\end{array} RENTLENGTH shows the number of days for the rental number (RTN) shown in table RENTALS. In a database used in reality, this table would be merged with the RENTALS table.
-SELECT DISTINCT CNAME,AGE FROM CUSTOMER,RENTALS
WHERE CUSTOMER.CID <> RENTALS.CID
The execution of this query produces the following number of rows:


Definitions:

Amazon

A multinational technology company primarily known for its e-commerce platform, cloud computing services, digital streaming, and artificial intelligence.

Proprietary, On-premise

This term describes software that is owned by a specific company and is installed and runs on computers on the premises of the organization using the software, as opposed to being cloud-based.

VMI

Vendor Managed Inventory, a business model in which the supplier of goods, rather than the retailer, is responsible for managing and replenishing inventory.

Walmart And P&G

Two major corporations, Walmart, a retail giant, and Procter & Gamble (P&G), a multinational consumer goods company, known for their strategic partnerships and business relations.

Related Questions