dotnet / dotnet/efcore

Support generating split queries from LINQ joins

Open
#27,376 0 comments 1 reaction 0 assignees View on GitHub
area-query customer-reported needs-design
Dominant language
C#
Stars
14.8k
Forks
3.4k
PR merge metrics
PR metrics pending

Description

### Problem
I want to improve performace spliting queries. But I'm Working with DDD Aggregates, so as a best practice we're not using reference properties (navigation properties) in the models relations (many to one).

So we can't use "Include" to split queries. Right now we use Linq Joins to access related properties.

### Solution idea
Use a Linq Join with a DTO (which has the related props). When AsSplitQuery is chained with the Join, the query generated is separated and mapped to the DTO(or anonymous type) based on the third parameter of the Join.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.