LINQ: The Good, The Bad, and The Poorly Optimized (Part 2)

Part 2: Controlling Parameter Optimization with Plan Guides For Part 1 of this series, see LINQ: The Good, The Bad, and The Poorly Optimized. T-SQL supports a variety of “hints”. They are hints in the same sense that your mother used to hint that it’s time to wash up and come to dinner. In other […]
Read More ›

LINQ: The Good, The Bad, and The Poorly Optimized (Part 1)

Part I: LINQ and sp_executesql Numerous questions raised in numerous forums mention that LINQ to SQL wraps queries in a call to the stored procedure sp_executesql. There seems to be agreement that this is done to ensure the caching of the query and query parameterization (if, indeed, parameters are supplied). Some advantages to sp_executesql, like […]
Read More ›

Precompiling LINQ Queries in .NET Framework 4.5

While it is possible to precompile LINQ queries for Entity Framework either to have your queries run faster (either without parameters or with parameters) or to run your queries on a background thread, in .NET Framework 3.5/4, it’s neither pretty nor fun. The code isn’t particularly ugly but it does require some additional effort for […]
Read More ›

Calling LINQ Queries in the Background

In my last two posts (here and here), I showed how you can pre-compile a LINQ query to improve your performance. As I noted in those posts, I wouldn’t expect a blinding improvement in response times—your application probably doesn’t have many really complex queries and, as a result, probably doesn’t spend a lot of time converting […]
Read More ›

PreCompiling LINQ Queries with Parameters

In my last post, I looked at precompiling a LINQ query to speed up (at least a little bit) your application. The LINQ statement I used as my example was very simple: Dim res = From o In en.Orders           Select o This post looks at a more realistic example: a LINQ statement that has a Where clause. […]
Read More ›

Type to search blog.learningtree.com

Do you mean "" ?

Sorry, no results were found for your query.

Please check your spelling and try your search again.