I am trying to use batch updates in Access VBA. My code works fine when I update after every operation, but fails when I try to operate on multiple rows. The exception I get is
"Run-time error '-2147217887 (80040e21)': Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done."
My code is
rs.Open "dbrammDump", CurrentProject.Connection, _
adOpenKeyset, adLockBatchOptimistic
rowsDel = 0
Do Until rs.RecordCount < 1
rs.MoveFirst
rs.Delete
rowsDel = rowsDel + 1
Loop
rs.UpdateBatch
Any ideas what the issue is?