CSC 350 Quiz 7

Lakukan tugas rumah & ujian kamu dengan baik sekarang menggunakan Quizwiz!

What results would the following SQL statement produce? select owner, table_name from dba_tables where table_name = 'CUSTOMER';

A listing of the owner of the customer table

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

A report is desired that lists all customers, 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).

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

DBA_USERS

EXISTS takes a value of false if the subquery returns an intermediate result set

False

The following query will execute without errors. select customer.customer_name, salesman.sales_quota from customer where customer.salesman_id = (select salesman_id where lname = 'SMITH');

False

The natural join is very rarely used.

False

There is a special operation in SQL to join a table to itself.

False

Using an outer join produces this information: rows that do not have matching values in common columns are not included in the result table.

False

EXISTS will take a value of ________ if the subquery returns an intermediate results table which contains one or more rows. A) FALSE B) 1 C) TRUE D) undefined

TRUE

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)

True

A join in which the joining condition is based on equality between values in the common columns is called a(n): A) equi-join. B) unilateral join. C) natural join. D) both A and C.

both A and C.

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

correlated

If the DBA wishes to describe all tables in the database, which data dictionary view should be accessed in Oracle?

dba_tables

One major advantage of the outer join is that: A) information is easily accessible. B) information is not lost. C) the query is easier to write. D) all of the above.

information is not lost.

Explicit commands to manage transactions are needed when:

multiple SQL commands must be run as part of a transaction.

The most commonly used form of join operation is the:

natural join.

While triggers run automatically, ________ do not and have to be called.

routines

All of the following are advantages of SQL-invoked routines EXCEPT: A) flexibility. B) efficiency. C) sharability. D) security.

security

A type of query that is placed within a WHERE or HAVING clause of another query is called a:

subquery

All of the following are guidelines for better query design EXCEPT: A) understand how indexes are used in query processing. B) use a lot of self-joins. C) write simple queries. D) retrieve on the data that you need.

use a lot of self-joins.


Set pelajaran terkait

Chapter 6 Operant Conditioning (Part 2)

View Set

NGN Mental Health Mental Health Concepts

View Set

Communication and Interpersonal Skills

View Set

Chapter 13 Digital Marketing and social media

View Set

All Previous Quiz Questions and Answers

View Set

MLS 301 All available practice quizes

View Set

Study Guide for Mid term Quiz Topic 4

View Set

NURSING 105: FUNDAMENTALS FINAL LIPPINCOTT CONCEPTS

View Set