I’m using EF along with mvc, for that I’ve a generic repository, unitOfWork implementation based on ObjectContext, no problem with CRUD so far. I’m just wondering how can/should I handle scenarios where I need to do the join with entities.
I’m using EF along with mvc, for that I’ve a generic repository, unitOfWork implementation
Share
There are couple of ways to handle the situation. Joins are not necessary in most situations and generally avoided in EF.
Generic Repository is a leaky abstraction. Implement specific repository for each entity and create method that does the join and return the result.