6
È possibile utilizzare let parola chiave con nibernate linq? Ho scrittoLINQ a NHibernate e let keyword
var posts = from post in postsRepository.GetPosts(name)
let commentsCount = (from c in NHUnitOfWork.CurrentSession.Linq<Comment>()
where c.Post.ID == post.ID
select c).Count()
select new ...
e in risposta ho
NHibernate.QueryException: impossibile risolvere proprietà: carica di: Sys.Domain.Entities.Post
Presumibilmente il tuo commento è collegato al tuo post? non potresti usare un operatore di gruppo? –