题解 | 短视频直播间晚上11-12点之间各直播间的在线人数

with t1 as (select user_id,room_id,out_time
from user_view_tb 
where out_time <='24:00:00' and out_time>='23:00:00')
select b.room_id,room_name,count(distinct user_id) as user_count
from t1 left join room_info_tb b on t1.room_id=b.room_id
group by b.room_id,room_name
order by user_count desc



全部评论

相关推荐

求offer的大角牛:不吃香菜
点赞 评论 收藏
分享
评论
1
收藏
分享

创作者周榜

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