Mid LINQ

Detect and avoid N+1 query in EF?

Detect and avoid N+1 query in EF?

Use Include() to load related entities:

var orders = dbContext.Orders

.Include(o => o.Customer)

.ToList();

More from LINQ Tutorial

All questions for this course