Appearance
DeleteByPkAsync Method
Definition
- Namespace:
JASE.Database - Assembly:
JASE.Database.dll
Overloads
| Name | Description |
|---|---|
Task<bool> DeleteByPkAsync(object id, int commandTimeout = null, CancellationToken cancellationToken = null) | Deletes a record by primary key value. |
Task<bool> DeleteByPkAsync(Type entityType, object id, int commandTimeout = null, CancellationToken cancellationToken = null) | Deletes a record by primary key value using a runtime entity type. |
Task<bool> DeleteByPkAsync(Type entityType, object id, int commandTimeout = null, CancellationToken cancellationToken = null)
csharp
Task<bool> DeleteByPkAsync(Type entityType, object id, int commandTimeout = null, CancellationToken cancellationToken = null)Deletes a record by primary key value using a runtime entity type.
Task<bool> DeleteByPkAsync(object id, int commandTimeout = null, CancellationToken cancellationToken = null)
csharp
Task<bool> DeleteByPkAsync(object id, int commandTimeout = null, CancellationToken cancellationToken = null)Deletes a record by primary key value.
Type parameters
| Name | Description |
|---|---|
T | The entity (row) type. |
Parameters
| Name | Description |
|---|---|
cancellationToken | Cancellation token. |
commandTimeout | Command timeout in seconds. Use -1 for provider default. |
id | Primary key value. |
Returns
true if a row was deleted; otherwise false.