Chapter 6 (Final) Flashcards

1
Q

An SQL query that implements an outer join will return rows that do not have matching values in common columns.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

It is better not to have a result set identified before writing GROUP BY and HAVING clauses for a query.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

A subquery in which processing the inner query depends on data from the outer query is called a codependent query.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

A join in which the joining condition is based on equality between values in the common column is called an equi-join.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

MULTISET is similar to the table datatype.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

The natural join is very rarely used.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

A join that is based upon equality between values in two common columns with the same name and where one duplicate column has been removed is called a(n):

A

natural-join

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

The ________ DBA view shows information about all users of the database in Oracle.

A

DBA_USERS

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Establishing IF-THEN-ELSE logical processing within an SQL statement can now be accomplished by using the CASE keyword in a statement.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

The following code is an example of a(n):

SELECT Customer_T.CustomerID, Order_T.CustomerID,
CustomerName, OrderID
FROM Customer_T, Order_T
WHERE Customer_T.CustomerID = Order_T. CustomerID;

A

equi-join.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

The outer join syntax does not apply easily to a join condition of more than ________ tables.

A

two

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

When a subquery is used in the FROM clause, it is called a denied table.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Subqueries can only be used in the WHERE clause.

A

False

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

A base table is the underlying table that is used to create views.

A

True

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

All of the following are advantages of SQL-invoked routines EXCEPT:

A

security.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

________ takes a value of TRUE if a subquery returns an intermediate results table which contains one or more rows.

A

Exists

17
Q

All of the following are part of the coding structure for triggers EXCEPT:

A

selection

18
Q

In which of the following situations would one have to use an outer join in order to obtain the desired results?

A

A report is desired that lists all customers and the total of their orders during the most recent month, and includes customers who did not place an order during the month (their total will be zero).

19
Q

EXISTS will take a value of ________ if the subquery returns an intermediate results table which contains one or more rows.

A

true

20
Q

A ________ is a temporary table used in the FROM clause of an SQL query.

A

derived table

21
Q

The following code would include:

SELECT Customer_T.CustomerID, Order_T.CustomerID,
CustomerName, OrderID
FROM Customer_T, Order_T
WHERE Customer_T.CustomerID = Order_T. CustomerID;

A

only rows that match both Customer_T and Order_T Tables.

22
Q

The advantages of SQL-invoked routines are flexibility, efficiency, sharability, and applicability.

A

True

23
Q

The following SQL statement is an example of a correlated subquery.

SELECT First_Name, Last_Name, Total_Sales
FROM Salesman s1
WHERE Total_Sales > all 
(SELECT Total_Sales FROM Salesman s2
WHERE s1.Salesman_ID != s2.Salesman_ID);
A

True

24
Q

In SQL, a(n) ________ subquery is a type of subquery in which processing the inner query depends on data from the outer query.

A

correlated

25
Q

The following code is an example of a:

SELECT CustomerName, CustomerAddress, CustomerCity, CustomerState,
CustomerPostalCode
FROM Customer_T
WHERE Customer_T.CustomerID =
(SELECT Order_T.CustomerID
FROM Order_T
WHERE OrderID = 1008);
A

subquery