Oracle
1Z0-047 · Question #195
View the Exhibit and examine the details of the ORDER_ITEMS table. Evaluate the following SQL statements: Statement 1: SELECT MAX(unit_pricequantity) "Maximum Order" FROM order items; Statement 2…
The correct answer is A. Statement 1 would return only one row of output. C. Statement 2 would return multiple rows of output. E. Both statements would ignore NULL values for the UNIT_PRICE and QUANTITY columns. See the full explanation below for the reasoning.
Question
View the Exhibit and examine the details of the ORDER_ITEMS table. Evaluate the following 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 statements are true regarding the output of these SQL statements? (Choose all that apply.)
Exhibit
Options
- AStatement 1 would return only one row of output.
- BBoth the statements would give the same output.
- CStatement 2 would return multiple rows of output.
- DStatement 1 would not return any row because the GROUP BY clause is missing.
- EBoth statements would ignore NULL values for the UNIT_PRICE and QUANTITY columns.
How the community answered
(40 responses)- A75% (30)
- B10% (4)
- D15% (6)
Community Discussion
No community discussion yet for this question.
