总之就是非常可爱
总之就是非常可爱
全部文章
分类
题解(177)
归档
标签
去牛客网
登录
/
注册
总之就是非常可爱的博客
全部文章
(共12篇)
题解 | #插入记录(一)#
insert into exam_record values(null,1001,9001,'2021-09-01 22:11:12','2021-09-01 23:01:12',90), (null,1002,9002,'2021-09-04 07:01:02',null,null);
Mysql
2022-05-23
1
392
题解 | #21年8月份练题总数#
select count(distinct device_id) as did_cnt,count(question_id) as question_cnt from question_practice_detail where month(date)=8&&year(date)=2...
Mysql
2022-05-23
1
359
题解 | #截取出年龄#
select substring_index(substring_index(profile,',',-2),',',1) as age,count(device_id) as number from user_submit group by age; //详细看substri...
Mysql
2022-05-23
1
405
题解 | #统计每种性别的人数#
select case when profile like '%,male' then 'male' when profile like '%,female' then 'female' end gender ,count(device_id) from user_submit gr...
Mysql
2022-05-23
0
315
题解 | #查看不同年龄段的用户明细#
select day(date) as day ,count(device_id) as question_cnt from question_practice_detail where year(date)=2021&&month(date)=8 group by date;
Mysql
2022-05-23
1
314
题解 | #查看不同年龄段的用户明细#
select device_id,gender,'20-24岁' from user_profile where age>=20&&age<=24 union select device_id,gender,'25岁及以上' from user_profile...
Mysql
2022-05-23
1
399
题解 | #计算25岁以上和以下的用户数量#
select '25岁以下',count(id) from user_profile where age is null||age<25 union select '25岁及以上',count(id) from user_profile where age>=25; ...
Mysql
2022-05-23
2
394
题解 | #查找山东大学或者性别为男生的信息#
select up.device_id,up.gender,up.age,up.gpa from user_profile up where up.university='山东大学' union all select up.device_id,up.gender,up.age,up.gpa fr...
Mysql
2022-05-21
1
270
题解 | #统计每个用户的平均刷题数#
select up.university,qd.difficult_level,count(qpd.device_id)/count(distinct up.device_id) from user_profile up,question_practice_detail qpd,question_d...
Mysql
2022-05-21
1
296
题解 | #统计每个学校各难度的用户平均刷题数#
select up.university,qd.difficult_level,count(qpd.device_id)/count(distinct up.device_id) from user_profile up,question_practice_detail qpd,question_d...
Mysql
2022-05-21
3
335
首页
上一页
1
2
下一页
末页