DbExpressionBuilder.OrderByDescending 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
建立一個新檔案 DbSortExpression ,將指定排序鍵排序給定輸入,排序順序由降到低,預設排序方式。
多載
| 名稱 | Description |
|---|---|
| OrderByDescending(DbExpression, Func<DbExpression,DbExpression>) |
建立一個新檔案 DbSortExpression ,將指定排序鍵排序給定輸入,排序順序由降到低,預設排序方式。 |
| OrderByDescending(DbExpression, Func<DbExpression,DbExpression>, String) |
建立一個新檔案 DbSortExpression ,依指定排序鍵排序給定輸入,排序順序由降到低,並依照指定的排序方式排序。 |
OrderByDescending(DbExpression, Func<DbExpression,DbExpression>)
建立一個新檔案 DbSortExpression ,將指定排序鍵排序給定輸入,排序順序由降到低,預設排序方式。
public:
[System::Runtime::CompilerServices::Extension]
static System::Data::Common::CommandTrees::DbSortExpression ^ OrderByDescending(System::Data::Common::CommandTrees::DbExpression ^ source, Func<System::Data::Common::CommandTrees::DbExpression ^, System::Data::Common::CommandTrees::DbExpression ^> ^ sortKey);
public static System.Data.Common.CommandTrees.DbSortExpression OrderByDescending(this System.Data.Common.CommandTrees.DbExpression source, Func<System.Data.Common.CommandTrees.DbExpression,System.Data.Common.CommandTrees.DbExpression> sortKey);
static member OrderByDescending : System.Data.Common.CommandTrees.DbExpression * Func<System.Data.Common.CommandTrees.DbExpression, System.Data.Common.CommandTrees.DbExpression> -> System.Data.Common.CommandTrees.DbSortExpression
<Extension()>
Public Function OrderByDescending (source As DbExpression, sortKey As Func(Of DbExpression, DbExpression)) As DbSortExpression
參數
- source
- DbExpression
一個指定輸入集合的表達式。
- sortKey
- Func<DbExpression,DbExpression>
一種方法,規定如何在輸入集合成員下推導排序鍵表達式。 此方法必須產生一個具有順序可比較結果類型的表達式,以提供排序鍵的定義。
傳回
一個新的 DbSortExpression,代表 order-by 操作。
例外狀況
適用於
OrderByDescending(DbExpression, Func<DbExpression,DbExpression>, String)
建立一個新檔案 DbSortExpression ,依指定排序鍵排序給定輸入,排序順序由降到低,並依照指定的排序方式排序。
public:
[System::Runtime::CompilerServices::Extension]
static System::Data::Common::CommandTrees::DbSortExpression ^ OrderByDescending(System::Data::Common::CommandTrees::DbExpression ^ source, Func<System::Data::Common::CommandTrees::DbExpression ^, System::Data::Common::CommandTrees::DbExpression ^> ^ sortKey, System::String ^ collation);
public static System.Data.Common.CommandTrees.DbSortExpression OrderByDescending(this System.Data.Common.CommandTrees.DbExpression source, Func<System.Data.Common.CommandTrees.DbExpression,System.Data.Common.CommandTrees.DbExpression> sortKey, string collation);
static member OrderByDescending : System.Data.Common.CommandTrees.DbExpression * Func<System.Data.Common.CommandTrees.DbExpression, System.Data.Common.CommandTrees.DbExpression> * string -> System.Data.Common.CommandTrees.DbSortExpression
<Extension()>
Public Function OrderByDescending (source As DbExpression, sortKey As Func(Of DbExpression, DbExpression), collation As String) As DbSortExpression
參數
- source
- DbExpression
一個指定輸入集合的表達式。
- sortKey
- Func<DbExpression,DbExpression>
一種方法,規定如何在輸入集合成員下推導排序鍵表達式。 此方法必須產生一個具有順序可比較結果類型的表達式,以提供排序鍵的定義。
- collation
- String
要整理的集合。
傳回
一個新的 DbSortExpression,代表 order-by 操作。
例外狀況
collation 是空的或僅包含空格字元。