爱喝胡辣汤
爱喝胡辣汤
全部文章
分类
归档
标签
去牛客网
登录
/
注册
爱喝胡辣汤的博客
全部文章
(共45篇)
题解 | #字符函数正则匹配2#
select id, comment from comment_detail where comment like '是%' or comment like '求%'
2023-07-01
3
305
题解 | #字符函数正则匹配1#
select id, comment from comment_detail where comment like '%是%' or comment like '试%' -- 什么狗j8题目啊?这组会员题目的质量?我再买会员就是狗
2023-07-01
18
246
题解 | #输出在5min内完成点击购买的用户ID#
select user_ad_click_time.user_id uid from user_ad_click_time left join user_payment_time on user_ad_click_time.user_id = user_payment_tim...
2023-07-01
10
493
题解 | #广告点击的高峰期#
select `hour` click_hour, count(click_cnt) click_cnt -- 根据子查询,按小时分组,统计各小时的点击量 from ( -- 这个子查询,统计出各小时的点击数量 select ...
2023-07-01
0
199
题解 | #验证刷题效果,输出题目真实通过率#
SELECT question_pass_rate_tab.user_id AS user_id, question_pass_rate, pass_rate, question_per_cnt FROM -- 1.question_pass_rate题目正确...
2023-07-01
0
257
题解 | #输出提交且通过次数大于2 的用户ID且升序排列#
select user_id from ( select user_id, count(*) qs_cnt, -- 统计提交次数 count(if(result_info = 1,result_i...
2023-07-01
0
138
题解 | #输出提交次数大于2次的用户ID且倒序排列#
select user_id from ( select user_id, count(*) qs_cnt -- 用户提交次数 from done_questions_record...
2023-07-01
0
170
题解 | #查询每天刷题通过数最多的前二名用户id和刷题数#
这个思路类似于 两张questions_pass_record表 分别是t1和t2。 首先从t1表里取出一个t1.pass_count,使用count(*)统计了t2表中同一日期内有几个比t1.pass_count大。 如果count()=0说明当前取出的pass_count是当天最大的,可以输出。...
2023-07-01
2
283
题解 | #21年8月份练题总数#
select count(distinct device_id) as did_cnt, count(question_id) as question_cnt from question_practice_detail where year (`date`) = '2...
2023-06-29
0
131
题解 | #浙大不同难度题目的正确率#
SELECT difficult_level, -- count(if(result = 'right',result,null)) as right_cnt, 统计正确的数量 -- COUNT(IF(result = 'wrong',result,NULL)) AS wro...
2023-06-29
0
205
首页
上一页
1
2
3
4
5
下一页
末页