Global Data Management Forum

 View Only

EF Core 7 - Bulk updates not implemented?

  • 1.  EF Core 7 - Bulk updates not implemented?

    Posted Fri September 29, 2023 02:43 PM

    I'm trying to implement a bulk update using the new ExecuteUpdate() method of EF Core 7. But this fails with a NotImplementedException and following call stack:

    I'm using IBM.EntityFrameworkCore Version 7.0.0.200 and DB2 for z/OS 13

    Is this feature really not implemented? If so, will it be implemented in a future version? 

    Or am I doing something wrong? My query looks like this:

    var rowsAffected = await (from entry in _dbContext.Entries
                        join folderEntry in _dbContext.Folders on entry.Id equals folderEntry.EntryId
                        select new
                        {
                            entry,
                            folderEntry.ValidFrom,
                            folderEntry.ValidUntil
                        }).ExecuteUpdateAsync(e => e.SetProperty(arg => arg.entry.StartDate, arg => arg.ValidFrom).SetProperty(arg => arg.entry.EndDate, arg => arg.ValidUntil));


    ------------------------------
    Christian Erbsmehl
    ------------------------------