MySqlBulkCopy.WriteToServerAsync method (1 of 3)
Asynchronously copies all rows in the supplied DataTable to the destination table specified by the DestinationTableName
property of the MySqlBulkCopy
object.
public ValueTask<MySqlBulkCopyResult> WriteToServerAsync(DataTable dataTable,
CancellationToken cancellationToken = default)
parameter | description |
---|---|
dataTable | The DataTable to copy. |
cancellationToken | A token to cancel the asynchronous operation. |
Return Value
A MySqlBulkCopyResult
with the result of the bulk copy operation.
See Also
- class MySqlBulkCopyResult
- class MySqlBulkCopy
- namespace MySqlConnector
- assembly MySqlConnector
MySqlBulkCopy.WriteToServerAsync method (2 of 3)
Asynchronously copies all rows in the supplied IDataReader to the destination table specified by the DestinationTableName
property of the MySqlBulkCopy
object.
public ValueTask<MySqlBulkCopyResult> WriteToServerAsync(IDataReader dataReader,
CancellationToken cancellationToken = default)
parameter | description |
---|---|
dataReader | The IDataReader to copy from. |
cancellationToken | A token to cancel the asynchronous operation. |
Return Value
A MySqlBulkCopyResult
with the result of the bulk copy operation.
See Also
- class MySqlBulkCopyResult
- class MySqlBulkCopy
- namespace MySqlConnector
- assembly MySqlConnector
MySqlBulkCopy.WriteToServerAsync method (3 of 3)
Asynchronously copies all rows in the supplied sequence of DataRow objects to the destination table specified by the DestinationTableName
property of the MySqlBulkCopy
object. The number of columns to be read from the DataRow objects must be specified in advance.
public ValueTask<MySqlBulkCopyResult> WriteToServerAsync(IEnumerable<DataRow> dataRows,
int columnCount, CancellationToken cancellationToken = default)
parameter | description |
---|---|
dataRows | The collection of DataRow objects. |
columnCount | The number of columns to copy (in each row). |
cancellationToken | A token to cancel the asynchronous operation. |
Return Value
A MySqlBulkCopyResult
with the result of the bulk copy operation.
See Also
- class MySqlBulkCopyResult
- class MySqlBulkCopy
- namespace MySqlConnector
- assembly MySqlConnector