共用方式為


MigrationCommand 類別

定義

表示準備好要傳送至資料庫的命令,以便進行移轉。

public class MigrationCommand
type MigrationCommand = class
Public Class MigrationCommand
繼承
MigrationCommand

備註

如需詳細資訊和範例 ,請參閱資料庫移轉

建構函式

MigrationCommand(IRelationalCommand, Boolean)

建立 命令的新實例。

MigrationCommand(IRelationalCommand, DbContext, IDiagnosticsLogger<DbLoggerCategory.Database.Command>, Boolean)

建立 命令的新實例。

MigrationCommand(IRelationalCommand, DbContext, IRelationalCommandDiagnosticsLogger, Boolean)

建立 命令的新實例。

屬性

CommandLogger

相關聯的命令記錄器。

CommandText

將針對資料庫執行的 SQL 命令文字。

TransactionSuppressed

指出在執行命令時是否應該隱藏交易。

方法

ExecuteNonQuery(IRelationalConnection, IReadOnlyDictionary<String,Object>)

執行 命令,並傳回受影響的資料列數目。

ExecuteNonQuery(IRelationalConnection, IReadOnlyDictionary<String,Object>, Boolean)

表示準備好要傳送至資料庫的命令,以便進行移轉。

ExecuteNonQueryAsync(IRelationalConnection, IReadOnlyDictionary<String,Object>, Boolean, CancellationToken)

表示準備好要傳送至資料庫的命令,以便進行移轉。

ExecuteNonQueryAsync(IRelationalConnection, IReadOnlyDictionary<String,Object>, CancellationToken)

執行 命令,並傳回受影響的資料列數目。

適用於