Loading all the children entities with entity framework

前端 未结 3 2083
傲寒
傲寒 2020-12-03 05:02

I have a data model like this

\"Data

I would like to load all the related entities from a Recon

3条回答
  •  被撕碎了的回忆
    2020-12-03 05:46

    Not sure if it's to late but could you benefit from structuring your code such as

    var acctName = "someName";
    
    var detailList =  _repository.Include(e => e.JrnlEntryDetail).Filter(c => c.JrnlEntryDetail.Any(e => e.AcctName == acctName)).Get().ToList();
    

提交回复
热议问题