ObjectQuery<T>.SelectValue<TResultType> 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
將查詢結果限製為只有投影中指定的屬性。
public System.Data.Entity.Core.Objects.ObjectQuery<TResultType> SelectValue<TResultType>(string projection, params System.Data.Entity.Core.Objects.ObjectParameter[] parameters);
member this.SelectValue : string * System.Data.Entity.Core.Objects.ObjectParameter[] -> System.Data.Entity.Core.Objects.ObjectQuery<'ResultType>
Public Function SelectValue(Of TResultType) (projection As String, ParamArray parameters As ObjectParameter()) As ObjectQuery(Of TResultType)
類型參數
- TResultType
方法所回傳ObjectQuery<T>的類型SelectValue<TResultType>(String, ObjectParameter[])。
參數
- projection
- String
投影清單。
- parameters
- ObjectParameter[]
一組可選的查詢參數,解析時應該包含在範圍內。
傳回
ObjectQuery<TResultType>
一個與特定投影相容的類型新 ObjectQuery<T> 實例。 回傳 ObjectQuery<T> 的值等同於原始實例,並套用了 SELECT VALUE。
例外狀況
投影為空,或參數為空。
投影是一條空弦。