Skip to content

BulkInsertAsync Method ​

Definition ​

  • Namespace: JASE.Database
  • Assembly: JASE.Database.dll

Overloads ​

NameDescription
Task<int> BulkInsertAsync(IEnumerable<T> list, int commitInterval = null, int commandTimeout = null, CancellationToken cancellationToken = null)Inserts a list of records using provider-specific bulk techniques.
Task<int> BulkInsertAsync(Type entityType, IEnumerable list, int commitInterval = null, int commandTimeout = null, CancellationToken cancellationToken = null)Inserts a list of records using provider-specific bulk techniques and a runtime entity type.

Task<int> BulkInsertAsync(Type entityType, IEnumerable list, int commitInterval = null, int commandTimeout = null, CancellationToken cancellationToken = null) ​

csharp
Task<int> BulkInsertAsync(Type entityType, IEnumerable list, int commitInterval = null, int commandTimeout = null, CancellationToken cancellationToken = null)

Inserts a list of records using provider-specific bulk techniques and a runtime entity type.

Task<int> BulkInsertAsync(IEnumerable<T> list, int commitInterval = null, int commandTimeout = null, CancellationToken cancellationToken = null) ​

csharp
Task<int> BulkInsertAsync(IEnumerable<T> list, int commitInterval = null, int commandTimeout = null, CancellationToken cancellationToken = null)

Inserts a list of records using provider-specific bulk techniques.

Type parameters ​

NameDescription
TThe entity (row) type.

Parameters ​

NameDescription
cancellationTokenCancellation token.
commandTimeoutCommand timeout in seconds. Use -1 for provider default.
commitIntervalBatch size for transactional commits or flushes.
listItems to insert.

Returns ​

The number of rows inserted.