Weekend Sale - Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: sntaclus

Consider the Information Engineering diagram shown in the exhibit for a building management company. Referential integrity must be maintained such that a building cannot be deleted when it has residents. Building_ID, R_ID, Room_Count and Room_Num are integer numbers, whereas Bldg_Name, Location and Res_Name are all represented by variable-length strings with a maximum of 20 characters. Which SQL statement best implements the relations shown in this diagram?

A.

CREATE TABLE BUILDING (

Building_ID INTEGER NOT NULL PRIMARY KEY,

Bldg_Name VARCHAR (20),

Location VARCHAR (20),

Room_Count INTEGER );

CREATE TABLE RESIDENT (

R_ID NOT NULL PRIMARY KEY,

Room_Num INTEGER,

Res_Name VARCHAR (20),

Building_ID INTEGER NOT NULL,

FOREIGN KEY Building_ID REFERENCES RESIDENT (Building_ID)

ON DELETE NO CHECK);

B.

CREATE TABLE BUILDING (

Building_ID INTEGER NOT NULL PRIMARY KEY,

Bldg_Name VARCHAR (20),

Location VARCHAR (20),

Room_Count INTEGER );

CREATE TABLE RESIDENT (

R_ID NOT NULL PRIMARY KEY,

Room_Num INTEGER,

Res_Name VARCHAR (20),

Building_ID INTEGER NOT NULL,

FOREIGN KEY Building_ID REFERENCES BUILDING (Building_ID)

ON DELETE NO CHECK

ON UPDATE CASCADE);

C.

CREATE TABLE BUILDING (

Building_ID INTEGER NOT NULL PRIMARY KEY,

Bldg_Name VARCHAR (20),

Location VARCHAR (20),

Room_Count INTEGER );

CREATE TABLE RESIDENT (

R_ID NOT NULL PRIMARY KEY,

Room_Num INTEGER,

Res_Name VARCHAR (20),

Building_ID INTEGER NOT NULL,

FOREIGN KEY Building_ID REFERENCES BUILDING (Building_ID)

ON DELETE NO CHECK

ON UPDATE CASCADE);

D.

CREATE TABLE BUILDING (

Building_ID INTEGER NOT NULL PRIMARY KEY,

Bldg_Name VARCHAR (20),

Location VARCHAR (20),

Room_Count INTEGER );

CREATE TABLE RESIDENT (

R_ID NOT NULL PRIMARY KEY,

Room_Num INTEGER,

Res_Name VARCHAR (20),

Building_ID INTEGER NOT NULL,

FOREIGN KEY Building_ID REFERENCES BUILDING (Building_ID)

ON DELETE NO CHECK

ON UPDATE CASCADE);

Which characteristic is an advantage of a database management system?

A.

Data files are owned and maintained by the users.

B.

Database administration is simplified.

C.

A standard method can be used to access the database.

D.

Data is decentralized.

Consider the Dept1_Parts and Dept2_Parts relations shown in the exhibit. Which of the following SQL statements would create a set difference of the two relations with the widest variety of Structured Query Language dialects?

A.

SELECT *

FROM Dept1_Parts

EXCEPT

(SELECT Part_ID

FROM Dept2_Parts);

B.

SELECT *

FROM Dept1_Parts

MINUS

(SELECT Part_ID

FROM Dept2_Parts);

C.

SELECT *

FROM Dept1_Parts

DIFFERENCE

(SELECT Part_ID

FROM Dept2_Parts);

D.

SELECT *

FROM Dept1_Parts

DIFFERENCE

(SELECT Part_ID

FROM Dept2_Parts);

Consider the relations shown in the exhibit. Due to restructuring, the sales department has been eliminated and the employees working in that department have been dismissed. All ID information is stored as integers. Which SQL statement would be used to return a relation with all information for the employees who have been dismissed?

A.

SELECT *

FROM Employee;

B.

SELECT ID, Last_Name

FROM Employee;

WHERE ID = 0004;

C.

SELECT *

FROM Employee

WHERE Dept_ID = 022;

D.

SELECT *

FROM Employee

WHERE Dept_ID = 022;

What is a data dictionary?

A.

A system catalog containing user data

B.

An area of the database that is directly accessible by the user

C.

Data that is stored in tables and is only accessible by the DBMS

D.

Metadata that is stored in tables and is only accessible by the DBMS

What is a relational database domain?

A.

A group of attributes

B.

A set of permissible tuple values

C.

A collection of related data items

D.

A set of permissible attribute values

Which statement is used to define a named group of related tables, views, domains and other database objects?

A.

CREATE

B.

CREATE TABLE

C.

CREATE DOMAIN

D.

CREATE SCHEMA

For the Employee relation shown in the exhibit, which set of column value holds the complete tuple for the employee named James Smith?

A.

0002, James, Smith

B.

0002, James, Smith, 10-25-76

C.

First_Name, James, Last_Name, Smith

D.

Emp_ID, 0002, First_Name, James, Last_Name, Smith

Which of the following occurs in a relation when records are added or removed?

A.

The number of domains changes.

B.

The attributes in the domain change.

C.

The cardinality of the relation is fixed but the degree varies.

D.

The degree of the relation is fixed but the cardinality varies.

Consider the following relational algebraic expression as well as the Dept1_Parta and Dept2_Parts relations shown in the exhibit: Which of the following relations would result form the given relational algebraic expression?

A.

Option A

B.

Option B

C.

Option C

D.

Option D