nerdexam
Oracle

1Z0-047 · Question #159

View the Exhibit and examine the structure for the ORDERS and ORDER_ITEMS tables. You want to display ORDER_ID, PRODUCT_ID, and TOTAL (UNIT_PRICE multiplied by QUANTITY) for all the orders placed in…

The correct answer is D. SELECT o.order_id, oi.product_id, oi.unit_price*oi.quantity "TOTAL" FROM order_items oi JOIN orders o. See the full explanation below for the reasoning.

Question

View the Exhibit and examine the structure for the ORDERS and ORDER_ITEMS tables. You want to display ORDER_ID, PRODUCT_ID, and TOTAL (UNIT_PRICE multiplied by QUANTITY) for all the orders placed in the last seven days. Which query would you execute?

Exhibit

1Z0-047 question #159 exhibit

Options

  • ASELECT order_id, product_id, unit_price*quantity "TOTAL" FROM order_items oi JOIN orders o
  • BSELECT o.order_id,oi.product_id, oi.unit_price*oi.quantity " TOTAL" FROM order_items oi JOIN orders o
  • CSELECT o.order_id, oi.product_id, oi.unit_price*oi.quantity "TOTAL" FROM order_items oi JOIN orders o
  • DSELECT o.order_id, oi.product_id, oi.unit_price*oi.quantity "TOTAL" FROM order_items oi JOIN orders o

How the community answered

(45 responses)
  • A
    11% (5)
  • B
    7% (3)
  • C
    2% (1)
  • D
    80% (36)

Community Discussion

No community discussion yet for this question.

Full 1Z0-047 Practice