牛客368501572号
牛客368501572号
全部文章
分类
题解(22)
归档
标签
去牛客网
登录
/
注册
牛客368501572号的博客
全部文章
(共22篇)
题解 | #得分不小于平均分的最低分#
select min(score) min_score_over_avg from exam_record join examination_info using(exam_id) where tag='SQL' and score >=&n...
Mysql
2021-12-17
0
279
题解 | #某乎问答单日回答问题数大于等于3个的所有用户#
answer_date, author_id, count(*) answer_cnt from answer_tb where date_format( answer_date,'%Y-%m')='2021-11' group by answer_date,author_id ...
Mysql
2021-12-15
0
326
题解 | #某宝店铺的实际销售额与客单价#
sum(sales_price), round(sum(sales_price)/ count(distinct user_id),2) from sales_tb where date_format(sales_date,'%Y-%m')='2021-11'
Mysql
2021-12-15
0
270
题解 | #某宝店铺的SPU数量#
select style_id, count(distinct item_id) SPU_num from product_tb group by style_id ...
Mysql
2021-12-15
1
426
题解 | #某宝店铺的SPU数量#
select style_id, count(distinct item_id) SPU_num from product_tb group by style_id ...
Mysql
2021-12-15
0
369
题解 | #某乎问答高质量的回答中用户属于各级别的数量#
select case when author_level in (1,2) then '1-2级' &nb...
Mysql
2021-12-15
0
407
题解 | #统计2021年10月每个退货率不大于0.5的商品各项指标#
select answer_date, round(count(issue_id)/count(distinct author_id),2) per_num from ans...
Mysql
2021-12-15
4
400
题解 | #统计2021年10月每个退货率不大于0.5的商品各项指标#
ifnull() 考虑分为为0 的情况,在本题中不加也没有问题 select product_id, ifnull(round(sum(if_click)/ count(id),3),0) ctr, if...
Mysql
2021-12-15
7
680
题解 | #统计2021年10月每个退货率不大于0.5的商品各项指标#
select product_id, round(sum(if_click)/ count(id),3) ctr, round(sum(if_cart)/ sum(if_click),3) ...
Mysql
2021-12-15
1
402
题解 | #每天的日活数及新用户占比#
select t1.dt dt, count(distinct t1.uid) dau, round(count(...
Mysql
2021-12-15
8
351
首页
上一页
1
2
3
下一页
末页