ObjectQuery<T>.Select Method (String, ObjectParameter[])

 

Limits the query results to only the properties that are defined in the specified projection.

Namespace:   System.Data.Entity.Core.Objects
Assembly:  EntityFramework (in EntityFramework.dll)

public ObjectQuery<DbDataRecord> Select(
	string projection,
	params ObjectParameter[] parameters
)

Parameters

projection
Type: System.String

The list of selected properties that defines the projection.

parameters
Type: System.Data.Entity.Core.Objects.ObjectParameter[]

Zero or more parameters that are used in this method.

Return Value

Type: System.Data.Entity.Core.Objects.ObjectQuery<DbDataRecord>

A new ObjectQuery<T> instance of type DbDataRecord that is equivalent to the original instance with SELECT applied.

Exception Condition
ArgumentNullException

projection is null or parameters is null.

ArgumentException

The projection is an empty string.