Client-side evaluation happens when an ORM cannot translate part of a query into SQL, so the filtering must happen in application memory. A custom C# helper such as CalculateAge(u.DOB) can trigger the problem. section 8.3.2
The consequences depend on the ORM:
- Older ORMs such as EF6 could silently fetch the whole table and filter it in memory; a query meant to return 10 rows could fetch 10 million. section 8.3.2
- EF Core 3+ throws a runtime exception when it cannot translate the expression, protecting the database but failing the request. section 8.3.2
- Rewrite the query using SQL-compatible logic, or explicitly fetch only the needed data before filtering it in memory. section 8.3.2
