QuestionQ26

VerifiedDisplaying Data from Multiple Tables

Refer to the Exhibit and review the structures of the PROMOTIONS, SALES, and CUSTOMER tables.

Question Image

You must generate a report that displays the promo name with the customer name for every product sold during its promo campaign and before 30th October 2007. You issue this query:

Question Image

Which statement is true about the preceding query?

Explanation

The query is syntactically valid: an inner join can use both an equality condition and a range (BETWEEN) condition. However, it does not join SALES to PROMOTIONS by PROMO_ID. Testing only whether TIME_ID falls between a promotion's begin and end dates can associate a sale with an unrelated promotion that was active on the same date, so the result does not meet the required association.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!