首页
题库
公司真题
专项练习
面试题库
在线编程
面试
面试经验
AI 模拟面试
简历
求职
学习
基础学习课
实战项目课
求职辅导课
专栏&文章
竞赛
我要招人
发布职位
发布职位、邀约牛人
更多企业解决方案
AI面试、笔试、校招、雇品
HR免费试用AI面试
最新面试提效必备
登录
/
注册
已注销
获赞
0
粉丝
0
关注
0
看过 TA
4
IP属地:上海
暂未填写个人简介
私信
关注
拉黑
举报
举报
确定要拉黑已注销吗?
发布(27)
评论
刷题
收藏
已注销
关注TA,不错过内容更新
关注
01-16 21:49
题解 | 日活与每日次日留存率
select t1.visit_date, count(t1.id) dau, count(t2.id) / count(t1.id) next_day_per from user_visit_log t1 left join user_visit_log t2 on t1.id = t2.id and datediff (t2.visit_date, t1.visit_date) = 1 group by t1.visit_date
0
点赞
评论
收藏
分享
01-16 21:36
题解 | 话题的分布情况
select substring_index(subject_set, ',', 1) subject_id1,COUNT(*) cnt from comment_detail where find_in_set('1002', subject_set) group by subject_id1 order by subject_id1
0
点赞
评论
收藏
分享
01-16 21:20
题解 | 验证刷题效果,输出题目真实通过率
select user_id, COUNT(DISTINCT CASE WHEN result_info = 1 THEN question_id ELSE NULL END) / count(distinct question_id) question_pass_rate, sum(result_info)/count(user_id) as pass_rate, count(*)/count(distinct question_id) as question_per_cnt from done_questions_record group by user_id having SUM(cas...
0
点赞
评论
收藏
分享
01-16 17:23
题解 | 查询用户刷题日期和下一次刷题日期
select user_id,date, lead(date) over(partition by user_id order by date) nextdate from questions_pass_record LEAD 函数是 SQL 中的窗口函数,它用于访问同一结果集中当前行的后一行的值。该函数对于执行时间序列分析、计算移动平均值等任务非常有用。LEAD 函数的语法如下:LEAD (scalar_expression [, offset] [, default]) OVER ([partition_by_clause] order_by_clause)scalar_expressio...
0
点赞
评论
收藏
分享
01-16 17:18
题解 | 查询每天刷题通过数最多的前二名用户id和刷题数
select tmp.date, tmp.user_id, tmp.pass_count from (select date, user_id, pass_count, rank() over (partition by date order by pass_count desc) rk from questions_pass_record ) tmp where rk <= 2 order by tmp.date
0
点赞
评论
收藏
分享
01-16 17:07
题解 | 输出在5min内完成点击购买的用户ID
select c.user_id uid from user_ad_click_time c left join user_payment_time p on c.trace_id=p.trace_id and c.user_id=p.user_id where timestampdiff (minute, c.click_time, p.pay_time)<=5 order by uid desc
0
点赞
评论
收藏
分享
01-16 16:48
题解 | 广告点击的高峰期
select hour(click_time) as click_hour, count(click_time) as click_cnt from user_ad_click_time c group by hour(click_time) order by click_cnt desc limit 1
0
点赞
评论
收藏
分享
01-16 15:58
题解 | 分群并计算群体人数
SELECT CASE WHEN age < 20 THEN '20以下' WHEN age >=20 and age <=50 THEN '20-50' WHEN age > 50 THEN '50以上' WHEN age IS NULL THEN '未填写' END AS age_group, COUNT(customer_id) AS user_count FROM customers_info GROUP BY age_group
0
点赞
评论
收藏
分享
01-16 15:23
题解 | 查询职位城市在北京或者职位工资高于100000的job_id和company_id,不去重
select job_id, company_id from job_info where job_city like '%北京%' Union all select job_id, company_id from job_info where salary > 100000
0
点赞
评论
收藏
分享
01-16 15:13
题解 | 查询被投递过的职位信息
select j.company_id, sum(d.resume_if_checked) cnt from deliver_record d join job_info j on d.job_id = j.job_id group by j.company_id having cnt !=0 order by j.company_id
0
点赞
评论
收藏
分享
01-16 14:55
题解 | 查询2022年毕业用户的刷题记录
SELECT * FROM questions_pass_record WHERE user_id in ( SELECT user_id FROM user_info WHERE graduation_year = '2022' )
0
点赞
评论
收藏
分享
01-16 14:37
题解 | 统计每天刷题数超过5的user_id以及刷题数
select date, user_id, sum(pass_count) total_pass_count from questions_pass_record_detail group by date,user_id having sum(pass_count)>5 #秋招的第一个offer,大家都拿到了吗#
0
点赞
评论
收藏
分享
1
2
创作者周榜
更多
关注他的用户也关注了:
牛客网
牛客企业服务