What are the best query types for querying a conceptual model in Entity Framework?

There are 3 ways to poll a conceptual model in EF:

  • LINQ to Entity
  • Entity SQL
  • Query building methods

Which one is best for which situation? Are there performance issues for these three types of queries?

+2


a source to share


1 answer


In general, all of these methods are suitable for production.

If you plan to reuse a LINQ to Entities query, use CompiledQuery. There are a number of performance features in Entity Framework: see this MSDN article .



+1


a source







All Articles