1.查找每个类别中单价最低的产品:
var categories =
from p in db.Products
group p by p.CategoryID into g
select new {
CategoryID = g.Key,
CheapestProducts =
from p2 in g
where p2.UnitPrice == g.Min(p3 => p3.UnitPrice)
select p2
};
更多: http://www.cnblogs.com/jara/p/3472215.html