Databases Reference
In-Depth Information
Method
Description
Returns the last element in a sequence or a default value if the
sequence contains no elements.
LastOrDefault
Returns the number of elements in a sequence as an Int64 value.
LongCount
Returns a maximum value in a sequence of numbers.
Max
Returns a minimum value in a sequence of numbers.
Min
Sorts the elements of a sequence in ascending order.
OrderBy
Sorts the elements of a sequence in descending order.
OrderByDescending
Inverts the order of the elements in a sequence.
Reverse
Projects each element of a sequence into a new form.
Select
Combines multiple sequences into one and projects each element
into a new form.
SelectMany
Determines whether two sequences contain equal elements.
SequenceEqual
Returns the only element of a sequence and throws an exception if
there is not exactly one element in the sequence.
Single
Returns the only element of a sequence or a default value if the
sequence is empty; this method throws an exception if there is
more than one element in the sequence.
SingleOrDefault
Bypasses a specified number of elements in a sequence and then
returns the remaining elements.
Skip
Bypasses elements in a sequence as long as a specified condition
is true and then returns the remaining elements.
SkipWhile
Computes the sum of a sequence of numeric values.
Sum
Returns a specified number of elements from the start of a
sequence.
Take
Returns elements from a sequence as long as a specified condition
is true.
TakeWhile
Performs a subsequent ordering of the elements in a sequence in
ascending order.
ThenBy
Performs a subsequent ordering of the elements in a sequence in
descending order
ThenByDescending
Returns distinct elements from two input sequences.
Union
Returns elements from a sequence that match the specified filter
criteria.
Where
Merges each element of the first sequence with an element that
has the same index in the second sequence.
Zip
A wealth of reference information about LINQ is available on MSDN. The following page
is a great starting point when you are looking for a quick example of a particular exten-
sion method or operator:
http://msdn.microsoft.com/en-us/vcsharp/aa336746.aspx
The following provides a complete reference of all LINQ extension methods available,
giving you a comprehensive, but more difficult-to-navigate, list:
http://msdn.microsoft.com/en-us/library/system.linq.queryable.aspx
 
Search WWH ::




Custom Search