/ Published in: C#

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
from p in PersonOrders // put your where clause here group p by p.PersonID into grp //could be grouped by anything, Grouping on Guid ID's is not a good idea let MaxOrderDatePerPerson = grp.Max ( g=>g.OrderDate ) from p in grp where p.OrderDate == MaxOrderDatePerPerson select p
Comments
