QUESTION NO: 32
View the Exhibit and examine the structure of the PROMOTIONS table.
You have to generate a report that displays the promo name and start date for all promos that
started after the last promo in the 'INTERNET' category.
Which query would give you the required output?
A.
SELECT promo_name, promo_begin_date FROM promotions
WHERE promo_begin_date > ALL (SELECT MAX(promo_begin_date) FROM promotions )AND
promo_category = 'INTERNET';
B.
SELECT promo_name, promo_begin_date FROM promotions
WHERE promo_begin_date IN (SELECT promo_begin_date
FROM promotions
WHERE promo_category='INTERNET');
C.
SELECT promo_name, promo_begin_date FROM promotions
WHERE promo_begin_date > ALL (SELECT promo_begin_date
FROM promotions
WHERE promo_category = 'INTERNET');
D.
SELECT promo_name, promo_begin_date FROM promotions
WHERE promo_begin_date > ANY (SELECT promo_begin_date
FROM promotions
WHERE promo_category = 'INTERNET');
Answer: C
答案解析:
参考:143:http://blog.csdn.net/rlhua/article/details/12884115
Explanation:
本文介绍了一种SQL查询方法,用于找出所有开始日期晚于某一类别(例如'INTERNET')中最后一条记录的促销活动。通过使用子查询和比较运算符,可以有效地筛选出符合条件的数据。

3706

被折叠的 条评论
为什么被折叠?



