牛客134017745号
牛客134017745号
全部文章
分类
归档
标签
去牛客网
登录
/
注册
牛客134017745号的博客
全部文章
(共20篇)
题解 | 2021年国庆在北京接单3次及以上的司机统计信息
with valid_order as ( select t1.city as city, t2.driver_id as driver_id, count(t2.order_id) as order_num, sum(ifnu...
2025-05-28
0
28
题解 | 近一个月发布的视频中热度最高的top3视频
with t1 as ( select t1.video_id, avg(if(timestampdiff(second, start_time, end_time)>=duration, 1, 0)) as finish_rate, s...
2025-04-24
0
37
题解 | 异常的邮件概率
select date, round(avg(type = 'no_completed'), 3) as p from email where send_id not in (select id from user where is_blacklist = 1) ...
2025-04-19
0
32
题解 | 牛客每个人最近的登录日期(五)
with new_login as ( select ifnull(cnt, 0) as new_cnt, login.date from login left join ( select ...
2025-04-19
0
36
题解 | 牛客的课程订单分析(七)
with satisfied_order as ( select (case client_id when 0 then 'GroupBuy' else name end) as source, count(*) over(partition by user_...
2025-04-17
0
26
题解 | 统计每个产品的销售情况
with t1 as ( # 求出产品ID、总销售额、单价、总销量、月平均销售额 select o.product_id as product_id, sum(quantity*unit_price) as total_sales, ...
2025-04-13
0
29
题解 | 各个部门实际平均薪资和男女员工实际平均薪资
with avg_sal as ( select department, staff_gender, normal_salary-dock_salary as salary from staff_tb ...
2025-04-13
0
36
题解 | 最受欢迎的top3课程
with popular_amount as( select c.cid as cid, count(uid) as pv, sum(timestampdiff(minute, start_time, end_time)) as time_le...
2025-04-13
0
36
题解 | 输出播放量最高的视频
with peak_uv_atonetime_count as ( select p1.cid as cid, sum(if((p1.start_time between p2.start_time and p2.end_time), 1, 0)) as pe...
2025-04-13
3
46
题解 | 每个顾客购买的最新产品名称
# 子查询 select o.customer_id, customer_name, product_name as latest_order from orders o join customers c on o.customer_id = c....
2025-04-13
0
34
首页
上一页
1
2
下一页
末页