旭寒丶
旭寒丶
全部文章
分类
归档
标签
去牛客网
登录
/
注册
旭寒丶的博客
全部文章
(共23篇)
题解 | 所有用户对高难度题目的刷题数
select up.device_id,cast(sum(case when difficult_level='hard' then 1 else 0 end) as signed) question_cnt from user_profile up left join question_pract...
2025-04-12
0
39
题解 | 学生数不大于2的学校的学生情况
select university,count(university) cnt,group_concat(device_id separator ";") device_list from user_profile group by university having cnt&l...
2025-04-11
0
36
题解 | 每个学校有哪些年龄的学生
select university,group_concat(distinct age order by age) age_concat from user_profile group by university concat_grouop 和 group by 一起用 用于拼接参数字段,可用d...
2025-04-11
0
34
题解 | 每个学校的平均年龄和平均绩点及整体情况
select university,avg_age,avg_gpa from (select ifnull(university,"总体") university,round(avg(age),3) avg_age,round(avg(gpa),3) avg_gpa from u...
2025-04-11
0
42
题解 | 筛选出学校名中包含特定关键词的用户
select id,device_id,university from user_profile where (university like "北京%" or university like "上海%") and (university like "...
2025-04-08
0
50
题解 | 分页显示第三页的结果
select * from user_profile order by device_id limit 6,3 知识点 limit 6,3 6指的是偏移量,3指的是要输出的长度,题干说3份数据为一页,两页总数据即为3*2
2025-04-08
0
39
题解 | 网易云音乐推荐(网易校招笔试真题)
select music_name from (select distinct music_name,music_id from follow join music_likes on follow.follower_id=music_likes.user_id join music on music...
2025-04-07
0
46
题解 | 支付间隔平均值
select cast(avg(abs(timestampdiff(second,ol.logtime,sl.logtime))) as SIGNED) gap from order_log ol join select_log sl on ol.order_id=sl.order_id abs ...
2025-04-07
0
28
题解 | 每天登陆最早的用户的内容喜好
select log_day,user_id,hobby from (select left(log_time,10) log_day,lt.user_id,hobby,rank()over(partition by left(log_time,10) order by log_time) firs...
2025-04-07
0
32
题解 | 统计加班员工占比
select department,concat(round(sum(times)/count(department)*100,1),'%') ratio from (select department,if(timestampdiff(minute,first_clockin,last_clock...
2025-04-07
0
31
首页
上一页
1
2
3
下一页
末页