Mid LINQ

Why use AsEnumerable()?

Why use AsEnumerable()?

var query = dbContext.Employees

.AsEnumerable() // switch to in-memory

.Where(e => CustomFunction(e.Name));

✅ Use when your logic can't be translated to SQL.

More from LINQ Tutorial

All questions for this course