题解 | #确定哪些订单购买了 prod_id 为 BR01

确定哪些订单购买了 prod_id 为 BR01 的产品(一)

https://www.nowcoder.com/practice/b692b0174c0444fa9452aee2d082fbbb

select cust_id,order_date from Orders 
where order_num in
(
    select  order_num from OrderItems
     where prod_id = 'BR01'
)
order by order_date asc

第四行的order_num 很容易写成prod_id,因此必须写对

全部评论

相关推荐

点赞 评论 收藏
分享
喜欢飞来飞去的雪碧在刷代码:可以试一试字节
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

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