Entity Framework Plus Query IncludeFilter - Security Access
Security Access (Include available related entities)
// myRoleID = 1; // Administrator // using Z.EntityFramework.Plus; // Don't forget to include this. var ctx = new EntitiesContext(); // LOAD posts and available comments for the role level. var posts= ctx.Posts.IncludeFilter(x => x.Comments.Where(y => y.RoleID >= myRoleID)) .ToList();