Proper way to access Navigational Properties
Hi, I trying to fetch data including the related data on other table. Is this the best way to to do it?
14 Replies
Unknown User•16mo ago
Message Not Public
Sign In & Join Server To View
do you really need all that data? and all at once?
if yes, then read this page first https://learn.microsoft.com/en-us/ef/core/querying/single-split-queries
Single vs. Split Queries - EF Core
Translating LINQ queries into single and split SQL queries with Entity Framework Core
Yes, this is only client information. But this is read only,
Does
AsNoTracking()
is not a good option?Unknown User•16mo ago
Message Not Public
Sign In & Join Server To View
I need all the information in the query.



Unknown User•16mo ago
Message Not Public
Sign In & Join Server To View
Here I have filters, Querying everything first then filter based on conditions like this


Like registration status :
Under review
Approved
Rejected
Unknown User•16mo ago
Message Not Public
Sign In & Join Server To View
Sorry I posted incomplete code. hehe
I try this method and it's working fine. Since someone suggest to use
AsSplitQuery()
what is the best one to use?
Unknown User•16mo ago
Message Not Public
Sign In & Join Server To View
the page I linked explains when/why you'd use AsSplitQuery