Oracle
1Z0-082 · Question #43
Table ORDER_ITEMS contains columns ORDER_ID, UNIT_PRICE and QUANTITY, of data type NUMBER. Examine these SQL statements: Statement 1: SELECT MAX(unit_price quantity) "Maximum Order" FROM…
Sign in or unlock 1Z0-082 to reveal the answer and full explanation for question #43. The question stem and answer options stay visible for context.
SQL and PL/SQL
Question
Table ORDER_ITEMS contains columns ORDER_ID, UNIT_PRICE and QUANTITY, of data type NUMBER. Examine these SQL statements:
Statement 1:
SELECT MAX(unit_price * quantity) “Maximum Order” FROM order_items; Statement 2:
SELECT MAX(unit_price * quantity) “Maximum Order” FROM order_items GROUP BY order_id; Which two statements are true?
Options
- AStatement 1 returns only one row of output.
- BStatement 2 returns only one row of output.
- CBoth statements will return NULL if either UNIT_PRICE or QUANTITY contains NULL.
- DBoth the statements give the same output.
- EStatement 2 may return multiple rows of output.
Unlock 1Z0-082 to see the answer
You've previewed enough free 1Z0-082 questions. Unlock 1Z0-082 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.
Topics
#MAX function#GROUP BY#NULL handling#aggregate functions