呼吸丶zero
呼吸丶zero
全部文章
分类
归档
标签
去牛客网
登录
/
注册
呼吸丶zero的博客
全部文章
(共33篇)
题解 | 查询出每个品牌在不同月份的总销售额以及购买该品牌商品的用户的平均年龄
select category_id ,sum(order_amount) as total_sales ,sum(case when customer_gender = '男' then 1 else 0 end) as male_customers ,sum(case when customer...
2025-07-23
0
44
题解 | 贷款情况
select city ,total_loan_amount ,average_loan_amount ,total_customers ,loan_type_name as most_applied_loan_type from ( select city ,round(sum(l...
2025-07-22
9
34
题解 | 查询出每个品牌在特定时间段内的退货率以及平均客户满意度评分
select brand_id ,brand_name ,round(sum(return_status)/count(*),2) as return_rate_July_2024 ,round(avg(customer_satisfaction_score),2) as average_custo...
2025-07-22
1
29
题解 | 分析每个员工在不同项目中的绩效情况
select employee_id, employee_name, performance_score as first_half_2024_score, row_number() over ( partition by pro...
2025-07-21
0
38
题解 | 分析每个商品在不同时间段的销售情况
with t as ( select product_id, product_name, sum(total_amount) as q2_2024_sales_total, cat...
2025-07-20
0
30
题解 | 最受欢迎的top3课程
select cid, count(*) as pv, floor(sum(tl)) as time_len from ( select cid, timestampdiff(second, start...
2025-07-18
1
38
题解 | 未下单用户统计
select cast(sum(case when product_id is null then 1 else 0 end) as signed ) as cnt from order_log right join user_info using(uid)
2025-07-16
0
25
题解 | 输出播放量最高的视频
WITH daily_events AS ( SELECT cid, DATE(event_time) AS dt, event_time, event_type FROM ( -- 生成开始事件 ...
2025-07-15
0
52
题解 | 每个顾客购买的最新产品名称
select customer_id ,customer_name ,product_name as latest_order from orders join customers using(customer_id) join products using(product_id) where (c...
2025-07-15
0
34
题解 | 每个顾客最近一次下单的订单信息
select order_id, customer_name, order_date from orders join customers using (customer_id) where order_date in ( select...
2025-07-14
0
38
首页
上一页
1
2
3
4
下一页
末页