I have a SQL query that I need to turn into Linq but for the life of me I cannot seem to group the results.
This is the original SQL query:
select UserLevel, count(UserLevel) as count, StudioId
from UserProfile
where CompletedSetup = 1
and userid in (select UserId from webpages_UsersInRoles where RoleId = 4)
group by StudioId, UserLevel
order by StudioId
and what it returns is something like
UserLevel Count StudioId
1 6 1
2 2 1
3 4 1