欧美1区2区3区激情无套,两个女人互添下身视频在线观看,久久av无码精品人妻系列,久久精品噜噜噜成人,末发育娇小性色xxxx

題解 | #每個6/7級用戶活躍情況#

每個6/7級用戶活躍情況

http://www.fangfengwang8.cn/practice/a32c7c8590324c96950417c57fa6ecd1

with tmp as
(
    (select 
        uid,
        'exam' as type,
        date_format(start_time, '%Y%m') as act_month,
        date_format(start_time, '%Y%m%d') as act_day
    from exam_record
    where uid in
            (select
                uid
            from user_info
            where level in (6, 7)
            )
    )

union all

    (select 
        uid,
        'practice' as type,
        date_format(submit_time, '%Y%m') as act_month,
        date_format(submit_time, '%Y%m%d') as act_day
    from practice_record
    where uid in
        (select
            uid
        from user_info
        where level in (6, 7)
        )
    )
)

select 
    a.uid
    ,count(distinct act_month) as act_month_total
    ,count(distinct if(year(act_day) = 2021, act_day, null)) as act_days_2021
    ,count(distinct if(type = 'exam' and year(act_day) = 2021, act_day, null)) as act_days_2021_exam
    ,count(distinct if(type = 'practice' and year(act_day) = 2021, act_day, null)) as act_days_2021_question
from tmp
right join 
    (select
        uid
    from user_info
    where level in (6, 7)
    ) a -- 防止活躍數(shù)均為0的被忽略
on a.uid = tmp.uid
group by a.uid
order by act_month_total desc, act_days_2021 desc
;

全部評論

相關(guān)推薦

05-07 13:29
已編輯
門頭溝學(xué)院 Java
北斗導(dǎo)航Compass低仿版:能不能先搞清楚優(yōu)先級啊,怎么可能是項(xiàng)目問題,項(xiàng)目很重要嗎?又沒學(xué)歷 又沒實(shí)習(xí)大廠憑啥約面?那玩具項(xiàng)目 沒應(yīng)用在真實(shí)生產(chǎn)環(huán)境下的 就算做上天又有什么用?早點(diǎn)找個小公司實(shí)習(xí) 拿小公司實(shí)習(xí)去投大廠實(shí)習(xí),這才是你現(xiàn)在該做的
投遞美團(tuán)等公司10個崗位 簡歷被掛麻了,求建議
點(diǎn)贊 評論 收藏
分享
勸退式:感覺有人回才是不正常的
點(diǎn)贊 評論 收藏
分享
評論
點(diǎn)贊
收藏
分享

創(chuàng)作者周榜

更多
??途W(wǎng)
??推髽I(yè)服務(wù)