DEV Community

Alverson Layne
Alverson Layne

Posted on

Answer: Entity Framework: How to disable lazy loading for specific query?

set the following code before the query you want to execute

context.Configuration.LazyLoadingEnabled = false;

Top comments (0)