Linq-to-SQL Grouping not ordering correctly
Posted
by Grant
on Stack Overflow
See other posts from Stack Overflow
or by Grant
Published on 2010-05-06T00:11:35Z
Indexed on
2010/05/06
0:18 UTC
Read the original article
Hit count: 584
Hi can someone help me convert this tsql statement into c# linq2sql?
select [series] from table group by [series] order by max([date]) desc
This is what i have so far - the list is not in correct order..
var x = from c in db.Table
orderby c.Date descending
group c by c.Series into d
select d.Key;
© Stack Overflow or respective owner