O'Reilly logo

Fluent Entity Framework by Rebecca M. Riordan

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Query execution

I’ve said that a query is kind of like a delegate, in that it is only executed when it’s triggered. Well, the detail is a little more complicated. (Isn’t it always?) Here are the rules:

Image Queries that return a singleton value are executed immediately. Examples of this kind of query are those that include the Average, Count or First expressions:

Image

Image Queries that return multiple values are executed when they’re iterated over. You’ll usually ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required