Nina is writing a MySQL query to list the descriptions of items in the CUPCAKES table, which are identified by PROD_ID values. The ORDER_LINE table includes product and quantity information from bakery orders, which are identified by ORDER_NUM values. What can she add to the following query to limit the list to descriptions of cupcakes purchased through order 342? SELECT DESCRIPTION FROM CUPCAKES WHERE
A) PROD_ID IN(ORDER_LINE WHERE(ORDER_NUM = '342') ) ;
B) EXISTS (PROD_ID WHERE (ORDER_LINE.ORDER_NUM = '342') ) ;
C) PROD_ID IN(SELECT PROD_ID FROM ORDER_LINE WHERE(ORDER_NUM = '342') ) ;
D) PROD_ID EXISTS(SELECT PROD_ID FROM ORDER_LINE WHERE(ORDER_NUM = '342') ) ;
Correct Answer:
Verified
Q11: The _ of two tables is the
Q12: You can use the IN operator to
Q13: The _ of two tables is a
Q14: To create a condition that is true
Q15: The product of two tables is formally
Q17: In a nested query, the outer query
Q18: In which type of join are all
Q19: You can use the ALL and ANY
Q20: To qualify a column name, precede the
Q21: Suppose you have an ADDRESS_BOOK table containing
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents