日期:2014-05-20 浏览次数:21138 次
var result = A.Where(c => c.Style == 1006) .GroupBy(g => g.UserId) .Select(e => new { id = e.Key, number = e.Count() }) .OrderByDescending(o => o.number);
------解决方案--------------------
var query=A.Where(w=>w.Style==1006) .GroupBy(g => g.UserId) .Select(s => new { id = s.Key, number = s.Count()}) .OrderByDescending(o => o.number);
------解决方案--------------------