题解 | #牛客的课程订单分析(六)#

牛客的课程订单分析(六)

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


with t as(
    select 
        distinct user_id,
        count(product_name) over(partition by user_id) cnt
    from order_info
    where status='completed' and date>'2025-10-15'
)


select 
    o.id,
    is_group_buy,
    c.name client_name
from order_info o
left join client c on o.client_id=c.id
left join t on o.user_id=t.user_id
where status='completed' 
and date>'2025-10-15'
and t.cnt>=2
and product_name in ('C++','Python','Java') 
order by o.id




全部评论

相关推荐

不愿透露姓名的神秘牛友
07-03 17:30
点赞 评论 收藏
分享
Gaynes:查看图片
点赞 评论 收藏
分享
05-19 19:57
蚌埠学院 Python
2237:Gpa70不算高,建议只写排名,个人技能不在多而在精,缩到8条以内。项目留一个含金量高的,减少间距弄到一页,硕士简历也就一页,本科不要写很多
实习,投递多份简历没人回...
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

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