题解 | #统计所有课程参加培训人次#

统计所有课程参加培训人次

https://www.nowcoder.com/practice/98aad5807cf34a3b960cc8a70ce03f53

select sum(
    case 
    when course in ('course1','course2','course3') then 1 
    when course in ("course1,course2","course1,course3","course2,course3") then 2 
    when course in ('course1,course2,course3') then 3
    else 0
    end 
 ) staff_nums
from cultivate_tb;

全部评论

相关推荐

评论
点赞
收藏
分享

创作者周榜

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