What are the common things that we can keep in mind while writing the LINQ to SQL query for optimizing or speeding up the LINQ to SQL?.
For example, ordinarily, LINQ to SQL must translate LINQ queries to SQL every time a query executes; this involves recursing the expression tree that makes up the query in several stages. What we do is like precompiling the query using the CompiledQuery
class.