Professional Documents
Culture Documents
Question #:1 View The Exhibit and Examine The Structure of The ORDER - ITEMS Table
Question #:1 View The Exhibit and Examine The Structure of The ORDER - ITEMS Table
View the Exhibit and examine the structure of the ORDER_ITEMS table.
FROM order_items
WHERE unit_price =
(SELECT MAX(unit_price)
FROM order_items
GROUP BY order_id);
You want to display the PRODUCT_ID of the product that has the highest UNIT_PRICE per ORDER_ID.
What correction should be made in the above SQL statement to achieve this?
A. Remove the GROUP BY clause from the subquery and place it in the main query
Question #:2
CREATE_TABLE orders
ord_date DATE,
item_no NUMBER(3),
B. The BETWEEN clause cannot be used twice for the same table.
C. The CHECK constraint cannot be placed on columns having the DATE data type.
D. ORD_NO and ITEM_NO cannot be used as a composite primary key because ORD_NO is also the
FOREIGN KEY.
Question #:3
View the Exhibit and examine the description for the SALES and CHANNELS tables.
Which statement is true regarding the result? (Choose the best answer.)
A. The statement will fail because the subquery in the VALUES clause is not enclosed within single
quotation marks.
B. The statement will fail because a subquery cannot be used in a VALUES clause.
C. The statement will execute and a new row will be inserted in the SALES table.
D. The statement will fail because the VALUES clause is not required with the subquery.
Question #:4
View the exhibit and examine the structure and data in the INVOICE table.
Question #:5
Which two are true about queries using set operators (UNION, UNION ALL, INTERSECT and MINUS?
A. The name off each column in the first Select list must match the name of the corresponding column In
each subsequent select list.
C. None of the set operators can be used when selecting CLOB columns.
Question #:6
Which statement is true about the INTERSECT operator used in compound queries?
B. Multiple INTERSECT operators are not possible in the same SQL statement.
C. It ignores NULLs.
Question #:7
Which two statements are true regarding the SQL GROUP BY clause? (Choose two.)
B. Using the WHERE clause after the GROUP BY clause excludes rows after creating groups.
C. The GROUP BY clause is mandatory if you are using an aggregating function in the SELECT clause.
D. Using the WHERE clause before the GROUP BY clause excludes rows before creating groups.
E. If the SELECT clause has an aggregating function, then columns without an aggregating function in the
SELECT clause should be included in the GROUP BY clause.
B. All users have permissions to access all information in the data dictionary by default.
C. The data dictionary is constantly updated to reflect changes to database objects, permissions, and data.