You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using this method to do insert if the data does not already exist otherwise update. However the PK Id column is always inserted as an empty guid. I'm using version 7.0.4.
My primary key has these attributes set:
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
I'm using this method to do insert if the data does not already exist otherwise update. However the PK Id column is always inserted as an empty guid. I'm using version 7.0.4.
My primary key has these attributes set:
[Key]
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
BulkConfig bulkConfig = new BulkConfig
{
UpdateByProperties = updateByProperties,
PropertiesToExcludeOnUpdate = excludedProperties,
PropertiesToExcludeOnCompare = excludeOnCompare,
SetOutputIdentity = true,
SqlBulkCopyOptions = SqlBulkCopyOptions.KeepIdentity
};
await _dbContext.BulkInsertOrUpdateAsync(models, bulkConfig);
The text was updated successfully, but these errors were encountered: