However, the join clause does not have access to any of
the properties employed by the Association attribute, thus limiting its flexibility.
LINQ to SQL also employs the same rules of query execution as a standard LINQ query, meaning
deferred and immediate. You recall that a deferred execution query is one that produces a sequence
of values, and the query is not executed until you iterate through the results (that is, iterate over the
query variable). An immediate executed query is one that returns a single value (such as a query that
returns a MAX value, or COUNT). These types of queries are executed immediately because a sequence
must be produced first to generate the result.
There are several components involved when a query is executed:
??‘ LINQ to SQL API
??‘ LINQ to SQL Provider
??‘ ADO Provider
Each of these components plays a pivotal role when executing a query. When a LINQ to SQL query is
executed, seven steps are taken to execute the query and return the results.
1. The LINQ to SQL API requests execution of the query on behalf of your application.
Pages:
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357