一道sql的疑问

[复制链接]
查看11 | 回复2 | 2005-2-28 12:57:00 | 显示全部楼层 |阅读模式
run this sql statement;
select id_number,description,price
from inventory
where manufacture_id in
(select manufacture_id
from inventory
where price>8.00
or quantity >1000);
which values will be displayed?
答案:
C.The id number,description,and price of items in inventory that are
priced greater than 8.00 or that have a quantity value granter than
1000 and have a manufacture id value.


D.The id number,description,and price of items in inventory that were
manufactured by a manufacture whth items in invertory that are priced
greater than 8.00 or with items in invertorythat are priced greater
than 8.00 or with items in inventory that have a quantity value granter
than 1000.
我选的是C,可正确答案是D,不明白是为什么?
回复

使用道具 举报

千问 | 2005-2-28 12:57:00 | 显示全部楼层
C应该为下面语句的结果:
select id_number,description,price
from inventory
where price>8.00
or quantity >1000;
回复

使用道具 举报

千问 | 2005-2-28 12:57:00 | 显示全部楼层
manufactured 不能为空
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行