Beginner |
|
Joined: Fri May 13, 2005 11:48 am Posts: 32
|
Hibernate version:1.2
SQL Server 2005
Object Graph: (Pseudo Code)
ApplicationAccess
.Application.Id = $appId
.UserAccesses.User = $user
Code:
Dim crit As ICriteria = sess.CreateCriteria(GetType(ApplicationAccess))
crit.Add(Expression.Eq("Application.Id", applicationId))
crit.CreateCriteria("UserAccess").Add(Expression.Eq("User", user))
Desired Result:
Return all ApplicationAccess objects that have an AppId = ?
and the user is in the useraccess collection.
Any and all help appreciated.
-d
|
|