题解 | #每月及截止当月的答题情况#

每月及截止当月的答题情况

https://www.nowcoder.com/practice/1ce93d5cec5c4243930fc5e8efaaca1e

select a.start_month,count(distinct uid) as mau,
count(distinct if(first_month=start_month,uid,null)) as month_add_uv,
max(count(distinct if(first_month=start_month,uid,null))) over(order by start_month) max_month_add_uv,
sum(count(distinct if(first_month=start_month,uid,null))) over(order by start_month)  cum_sum_uv
from(
  SELECT uid,
           min(date_format(start_time,"%Y%m")) over(partition by uid order by date_format(start_time,"%Y%m")) as first_month, 
        date_format(start_time,'%Y%m') as start_month
from exam_record
)a
group by a.start_month
    

全部评论

相关推荐

03-05 17:03
已编辑
浙江工商大学 C++
陈好好wy:整体看下来有点空空的感觉,可以把每一段项目经历都再完善一下,然后用小标题的形式写个两到三条,目前看有点太简单了,不太能看出具体在这个项目里做了什么工作。还是要尽量把自己做的工作以量化的形式体现在简历上呢。
双非本科求职如何逆袭
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务