参考这句:
var q = from p in db.Products where sex='m' group p by p.CategoryID into g select new { NumProducts = g.Count() };
参考这句:
var q = from p in db.Products where sex='m' group p by p.CategoryID into g select new { NumProducts = g.Count() };
173844862.Net高级部落