📅  最后修改于: 2022-03-11 15:04:55.781000             🧑  作者: Mango
var query = from s in Stock
group s by new {s.Id, s.SupId, s.Text, s.ExternalId} into g
select new {g.Key.Id, g.Key.SupId, g.Key.Text, g.Key.ExternalId, Count = g.Count()};