Hello Jesse Flint,
I have investigated the problem you are experiencing. As far as I saw the delay comes from the join in the query. I did not discover any problems with a query of this kind
var query = (from o
query = query.Where(o=>o.Name ==
However, if I add a join in the first statement, the execution is delayed. The generated SQL is different in both cases (applying a filter in and outside the original query definition) and we will look into what options we have for improving the performance.
In case you have an association between Applications and Applicants, you can benefit from traversing the relationship instead of using a join. I am not sure if using dynamic LINQ expressions will make any difference on the performance.
The invocation of methods on a query after a select is performed results in additional statements in the database server. This is because a select can return an anonymous type or a custom type which is not persistent and subsequent filtering forces the final parts of the query to be executed in memory. What can be done to improve the performance on the final query is delay the select clause until you have applied all the filtering and ordering. This can be achieved (depending on the complexity) with using a method syntax from the very start of the building the query.
Feel free to contact us if you have further questions.
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Telerik Public Issue Tracking
system and vote to affect the priority of the items