题解 | #检索并列出已订购产品的清单#

检索并列出已订购产品的清单

https://www.nowcoder.com/practice/674d99a46a96494d8267ae4d162ed459

# 方法一:
select order_num,prod_id,quantity
from OrderItems 
where (prod_id = 'BR01' or prod_id = 'BR02' or prod_id = 'BR03')
and quantity >=100;

# 方法二:
select order_num,prod_id,quantity
from OrderItems 
where prod_id in('BR01','BR02','BR03')
and quantity >=100;

# 方法三
select order_num,prod_id,quantity
from OrderItems 
where prod_id between 'BR01' and 'BR03'
and quantity >=100;

全部评论

相关推荐

08-15 13:55
门头沟学院 Java
点赞 评论 收藏
分享
评论
16
1
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务