共用方式為


IRelationalCommand.ExecuteNonQueryAsync 方法

定義

多載

ExecuteNonQueryAsync(RelationalCommandParameterObject, CancellationToken)

以非同步方式執行沒有結果的命令。

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

以非同步方式執行沒有結果的命令。

ExecuteNonQueryAsync(IRelationalConnection, IReadOnlyDictionary<String,Object>, Boolean, CancellationToken)
已淘汰.

以非同步方式執行沒有結果的命令。

ExecuteNonQueryAsync(RelationalCommandParameterObject, CancellationToken)

來源:
IRelationalCommand.cs
來源:
IRelationalCommand.cs
來源:
IRelationalCommand.cs
來源:
IRelationalCommand.cs

以非同步方式執行沒有結果的命令。

public System.Threading.Tasks.Task<int> ExecuteNonQueryAsync (Microsoft.EntityFrameworkCore.Storage.RelationalCommandParameterObject parameterObject, System.Threading.CancellationToken cancellationToken = default);
abstract member ExecuteNonQueryAsync : Microsoft.EntityFrameworkCore.Storage.RelationalCommandParameterObject * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
Public Function ExecuteNonQueryAsync (parameterObject As RelationalCommandParameterObject, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Integer)

參數

parameterObject
RelationalCommandParameterObject

這個方法的參數。

cancellationToken
CancellationToken

CancellationToken等候工作完成時要觀察的 。

傳回

代表非同步作業的工作。 工作結果包含受影響的資料列數目。

例外狀況

適用於

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

以非同步方式執行沒有結果的命令。

public System.Threading.Tasks.Task<int> ExecuteNonQueryAsync (Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Collections.Generic.IReadOnlyDictionary<string,object> parameterValues, System.Threading.CancellationToken cancellationToken = default);
abstract member ExecuteNonQueryAsync : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Collections.Generic.IReadOnlyDictionary<string, obj> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
Public Function ExecuteNonQueryAsync (connection As IRelationalConnection, parameterValues As IReadOnlyDictionary(Of String, Object), Optional cancellationToken As CancellationToken = Nothing) As Task(Of Integer)

參數

connection
IRelationalConnection

要對其執行的連線。

parameterValues
IReadOnlyDictionary<String,Object>

參數的值。

cancellationToken
CancellationToken

CancellationToken等候工作完成時要觀察的 。

傳回

代表非同步作業的工作。 工作結果包含受影響的資料列數目。

適用於

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

警告

Use overload without 'manageConnection' parameter

以非同步方式執行沒有結果的命令。

public System.Threading.Tasks.Task<int> ExecuteNonQueryAsync (Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Collections.Generic.IReadOnlyDictionary<string,object> parameterValues = default, bool manageConnection = true, System.Threading.CancellationToken cancellationToken = default);
[System.Obsolete("Use overload without 'manageConnection' parameter")]
public System.Threading.Tasks.Task<int> ExecuteNonQueryAsync (Microsoft.EntityFrameworkCore.Storage.IRelationalConnection connection, System.Collections.Generic.IReadOnlyDictionary<string,object> parameterValues, bool manageConnection, System.Threading.CancellationToken cancellationToken = default);
abstract member ExecuteNonQueryAsync : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Collections.Generic.IReadOnlyDictionary<string, obj> * bool * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
[<System.Obsolete("Use overload without 'manageConnection' parameter")>]
abstract member ExecuteNonQueryAsync : Microsoft.EntityFrameworkCore.Storage.IRelationalConnection * System.Collections.Generic.IReadOnlyDictionary<string, obj> * bool * System.Threading.CancellationToken -> System.Threading.Tasks.Task<int>
Public Function ExecuteNonQueryAsync (connection As IRelationalConnection, Optional parameterValues As IReadOnlyDictionary(Of String, Object) = Nothing, Optional manageConnection As Boolean = true, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Integer)
Public Function ExecuteNonQueryAsync (connection As IRelationalConnection, parameterValues As IReadOnlyDictionary(Of String, Object), manageConnection As Boolean, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Integer)

參數

connection
IRelationalConnection

要對其執行的連線。

parameterValues
IReadOnlyDictionary<String,Object>

參數的值。

manageConnection
Boolean

值,指出是否視需要開啟和關閉連線。

cancellationToken
CancellationToken

CancellationToken等候工作完成時要觀察的 。

傳回

代表非同步作業的工作。 工作結果包含受影響的資料列數目。

屬性

適用於