题解 | #返回更多的产品#
返回更多的产品
http://www.nowcoder.com/practice/dc91b7d2de3c4603a55995e83210f605
解题思路
这题很明显就是要用条件查询过滤条件,所以要用where, 题目要求最后返回的数据不能重复,所以要用distinct来去重。
代码实现
select distinct order_num
from OrderItems
where quantity >=100
返回更多的产品
http://www.nowcoder.com/practice/dc91b7d2de3c4603a55995e83210f605
这题很明显就是要用条件查询过滤条件,所以要用where, 题目要求最后返回的数据不能重复,所以要用distinct来去重。
select distinct order_num
from OrderItems
where quantity >=100
相关推荐