思路1自己想的,复杂版每个人的分数=sum(add)-sum(reduce)按照总积分 用窗口函数 添加一列dense_rank筛选dense_rank()值=1的数据 select t.user_id, t.name, t.total as grade_num from ( select distinct g.user_id, u.name, (ifnull(a.add_num,0) - ifnull(r.re_num,0)) as total, dense_rank()over(order...