DevForce Help Reference
Select<TSource,TResult>(IEntityQuery<TSource>,Expression<Func<TSource,TResult>>) Method
Example 


Projects each element of a sequence into a new form.
Syntax
'Declaration
 
<ExtensionAttribute()>
Public Overloads Shared Function Select
    (Of TSource,TResult)( _
   ByVal source As IEntityQuery(Of TSource), _
   ByVal selector As Expression(Of Func(Of TSource,TResult)) _
) As IEntityQuery(Of TResult)
'Usage
 
Dim source As IEntityQuery(Of TSource)
Dim selector As Expression(Of Func(Of TSource,TResult))
Dim value As IEntityQuery(Of TResult)
 
value = EntityQueryExtensions.Select(Of TSource, TResult)(source, selector)

Parameters

source
selector

Type Parameters

TSource
TResult
Example
var mgr = new DomainModelEntityManager();
var query = mgr.OrderSummaries.Where(o => o.ShipCountry == "UK").Select(o => new { o.Id, o.ShipCountry, o.OrderDate });
var list = query.ToList();
Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

EntityQueryExtensions Class
EntityQueryExtensions Members
Overload List

Send Feedback