Examlex

Solved

Figuer:
CUSTOMER (Primary Key = CID) RENTALS (Primary Key = RTN)

question 7

Multiple Choice

Figuer:
CUSTOMER (primary key = CID)  CID  CNAME  AGE  RESID_CITY  Cregion 10 BLACK 40 SD  SD 20 GREEN 25 SD  SD 30 JONES 30 La Mesa  SD 40 MARTIN 35 LA  LA 50 SIMON 22 Pomona  LA 60 VERNON 60 Poway  SD \begin{array}{|l|l|l|l|l|}\hline \text { CID } & \text { CNAME } & \text { AGE } & \text { RESID\_CITY } & \text { Cregion } \\\hline 10 & \text { BLACK } & 40 & \text { SD } & \text { SD } \\\hline 20 & \text { GREEN } & 25 & \text { SD } & \text { SD } \\\hline 30 & \text { JONES } & 30 & \text { La Mesa } & \text { SD } \\\hline 40 & \text { MARTIN } & 35 & \text { LA } & \text { LA } \\\hline 50 & \text { SIMON } & 22 & \text { Pomona } & \text { LA } \\\hline 60 & \text { VERNON } & 60 & \text { Poway } & \text { SD } \\\hline\end{array} RENTALS (primary key = RTN)  CID  MAKE  DATE_OUT  PICKUP  RETURN  RTN  VIN  DATE-IN 10 FORD  10-Oct-00  SD  SD 1 F1  01-Dec-00 10 GM 01 Jan-01  SD  LA 210 FORD 01 Feb-01  LA  SD 320 NISSAN 07Jul00 SD 4 N1 30 FORD 01Jul00 SD  SD 5 F2 30-Nov-00 30 GM 01-Dec-00  SD  SD 6 G1 40 FORD 01 Aug-00  LA  LA 7 F3 50 GM 01 Sep-00  LA  SD 8 G2 60 NISSAN 02-Jan-01  SD  LA 9\begin{array} { | l | l | l | l | l | l | l | l | } \hline \text { CID } & \text { MAKE } & \text { DATE\_OUT } & \text { PICKUP } & \text { RETURN } & \text { RTN } & \text { VIN } & \text { DATE-IN } \\\hline 10 & \text { FORD } & \text { 10-Oct-00 } & \text { SD } & \text { SD } & 1 & \text { F1 } & \text { 01-Dec-00 } \\\hline 10 & \text { GM } & 01 - \text { Jan-01 } & \text { SD } & \text { LA } & 2 & & \\\hline 10 & \text { FORD } & 01 - \text { Feb-01 } & \text { LA } & \text { SD } & 3 & & \\\hline 20 & \text { NISSAN } & 07 - J u l - 00 & \text { SD } & & 4 & \text { N1 } & \\\hline 30 & \text { FORD } & 01 - J u l - 00 & \text { SD } & \text { SD } & 5 & \text { F2 } & 30 \text {-Nov-00 } \\\hline 30 & \text { GM } & 01 - \text {-Dec-00 } & \text { SD } & \text { SD } & 6 & \text { G1 } & \\\hline 40 & \text { FORD } & 01 - \text { Aug-00 } & \text { LA } & \text { LA } & 7 & \text { F3 } & \\\hline 50 & \text { GM } & 01 - \text { Sep-00 } & \text { LA } & \text { SD } & 8 & \text { G2 } & \\\hline 60 & \text { NISSAN } & 02 \text {-Jan-01 } & \text { SD } & \text { LA } & 9 & & \\\hline\end{array} 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  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} In RENTCOST, COST shows the base cost of renting a given MAKE for one day.
CAR  VIN  MAKE  RENTED  AT  F1  FORD  NO  SD  F2  FORD  NO  SD  F3  FORD  YES  IR  F4  FORD  NO  LA  G1  GM  YES  SD  G2  GM  YES  SD  N1  NISSAN  YES  LA  N2  NISSAN  NO  LA  T1  TOYOTA  NO  IR  T2  TOYOTA  NO  IR  V1  VOLVO  NO  LA  V2  VOLVO  NO  LA \begin{array} { | l | l | l | l | } \hline \text { VIN } & \text { MAKE } & \text { RENTED } & \text { AT } \\\hline \text { F1 } & \text { FORD } & \text { NO } & \text { SD } \\\hline \text { F2 } & \text { FORD } & \text { NO } & \text { SD } \\\hline \text { F3 } & \text { FORD } & \text { YES } & \text { IR } \\\hline \text { F4 } & \text { FORD } & \text { NO } & \text { LA } \\\hline \text { G1 } & \text { GM } & \text { YES } & \text { SD } \\\hline \text { G2 } & \text { GM } & \text { YES } & \text { SD } \\\hline \text { N1 } & \text { NISSAN } & \text { YES } & \text { LA } \\\hline \text { N2 } & \text { NISSAN } & \text { NO } & \text { LA } \\\hline \text { T1 } & \text { TOYOTA } & \text { NO } & \text { IR } \\\hline \text { T2 } & \text { TOYOTA } & \text { NO } & \text { IR } \\\hline \text { V1 } & \text { VOLVO } & \text { NO } & \text { LA } \\\hline \text { V2 } & \text { VOLVO } & \text { NO } & \text { LA } \\\hline\end{array} 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 CUST_SD AS
SELECT * FROM CUSTOMER
WHERE Cregion = 'SD'
CREATE VIEW CUST_40D AS
SELECT CNAME, RENTALS.MAKE, RENTCOST.COST
FROM CUSTOMER, RENTALS, RENTCOST
WHERE CUSTOMER.CID = RENTALS.CID
AND RENTALS.MAKE = RENTCOST.MAKE
AND RENTCOST < 40
CREATE VIEW Make_View (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 number of rows in the view Make-View is:


Definitions:

Verstehen

A German term used in sociology that refers to the understanding of social phenomena from the actor's perspective.

Objectification

The act of treating a person as an object or commodity, often reducing them to their physical attributes or functions.

Symbolic Interaction

The process of people interacting with each other through the use of symbols, gestures, words, and other symbolic forms to create social realities.

Macrosociological Theory

An approach to sociology focusing on social systems and populations on a large scale, examining the social structures and processes that shape society.

Related Questions