Can anyone help with trying to do the following SQL in Linq to
NHibernate 3.2?

select act.Name from Activity act
where 1 =
(
  select top 1 p.Allow
  from Permissions p inner join Operations o on p.OperationId =
o.OperationId
  inner join Users u on p.UserId = u.UserId
  where p.EntitySecurityKey = act.ActivityId and o.Name = '/operation'
  and u.Name = 'user'
  order by p.Level desc, p.Allow asc
)

This works beautifully in SQL and Criteria API but I just cannot
fathom how to do the equivalent using Linq.

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

Reply via email to