我在看这个
注意不要急于同时获取多个集合属性.虽然这个声明可以正常工作: var employees = session.Query().Fetch(e => e.Subordinates).Fetch(e => e.Orders).ToList();
注意不要急于同时获取多个集合属性.虽然这个声明可以正常工作:
var employees = session.Query().Fetch(e => e.Subordinates).Fetch(e => e.Orders).ToList();
我需要获取2个引用,所以我需要做类似的事情.有没有更好的方法来做到这一点.
我不能这样做,.ThenFetchMany()因为它进入了儿童对象,但我在同一级别上的那些.
.ThenFetchMany()
nhibernate
nhibernate ×1