OrderBy on children in a LINQ Query
Posted
by
eka808
on Stack Overflow
See other posts from Stack Overflow
or by eka808
Published on 2011-01-10T13:12:20Z
Indexed on
2011/01/12
8:53 UTC
Read the original article
Hit count: 169
Hello everybody
I have a user entity who contains a one to many relationship with a role entity
So with this linq expression :
from user in USER_TABLE.Include("USERROLE_TABLE")
order by user.Name
select user
I can get users with related roles as a child. My problem is that i want to get roles of each user ordered alphabetically. How can i do that ? I googled a lot and don't find anything
Thank's by advance !
© Stack Overflow or respective owner