51
LINQ Standard Query
Operators
Understanding the different parts of a query operation and how those parts work together provides
the foundation for constructing efficient queries to retrieve and transform data from many different
sources, such as XML documents, SQL databases, .NET collections, and ADO.NET datasets. This
chapter will outline those parts and their uses.
This chapter builds on the query operation information you examined in Chapter 3, ??????LINQ
Queries,??™??™ by exploring the standard query operators, a set of methods that form the LINQ pattern,
a standard way of creating query expressions to project, filter, group, and transform data. The
standard query operators provide the capability to query any object that implements the IEnumerable
interface and IQueryable interface. You can think of the standard query operators much like
an API. In this case, the ??????API??™??™ is a set of methods.
This chapter begins with an overview of the standard query operators. It examines each operator in
detail, providing examples, and then ends with a full example using many of these operators.
Pages:
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119