select a,b,sum(c) as d from userinfo group by a,b 肯定是按A,B一起分组呀, 1-1-1 1-1-2 1-2-1 统计后就是 1-1---3 1-2---1