Final Exam - Chapter 8
Which of the following search patterns could be used to find the word HELLO in Oracle12c?
%H%
Which of the following operators would be most appropriate to determine whether or not the retail price of a book is at least $24.00?
>=
When the WHERE clause contains multiple types of operators, which of the following is resolved first?
arithmetic operations
Which of the following clauses is used to indicate a particular sort sequence for presenting query results?
ORDER BY
Which of the following operators can be used to combine search conditions?
AND
To instruct Oracle12c to sort data in ascending order, enter ____ after the column name in the ORDER BY clause.
ASC
To instruct Oracle12c to sort data in descending order, enter ____ after the column name in the WHERE clause.
DESC
Which of the following operators is used when the criteria is based upon a search pattern?
LIKE
Which of the following is NOT a comparison operator?
NOT
Based upon the contents of the BOOKS table in the accompanying figure, which of the following queries will retrieve all book titles that are in the Business or Computer category and have a retail price of more than $35.00?
SELECT title FROM booksWHERE (category = 'BUSINESS' OR category ='COMPUTER' ) AND retail >35;
Based upon the contents of the BOOKS table in the accompanying figure, which of the following queries will display the title and retail price of each book stored in the BOOKS table in order of category and retail price?
SELECT title, retail FROM books ORDER BY category, retail;
Which of the following clauses is used to restrict the rows returned by a query?
WHERE
Which of the following is a valid logical operator?
all the above (NOT, AND, OR)
Based upon the contents of the ORDERS table in the accompanying figure, which of the following queries will display all orders shipped between April 4, 2003 and April 5, 2003?
both b and c b - SELECT * FROM orders WHERE shipdate BETWEEN '04-APR-03' AND '05-APR-03'; c - SELECT * FROM orders WHERE shipdate >= '04-APR-03' AND shipdate <= '05-APR-03';
When the WHERE clause contains multiple types of operators, which of the following is resolved last?
logical operators
When sorting the results in ascending order, which of the following values will be presented first in the output?
numeric
Based upon the contents of the BOOKS table in the accompanying figure, which of the following queries will list all books stored in the BOOKS table with a retail price of more than $38 sorted by retail price?
SELECT * FROM books WHERE retail >38 ORDER BY retail;
Based upon the contents of the ORDERS table in the accompanying figure, which of the following queries will not list the orders that have been shipped to Atlanta or Seattle?
SELECT * FROM orders WHERE shipcity = 'Atlanta' OR shipcity = 'Seattle';