1

Why is ADO.NET throwng a DBConccurencyException, when I try to update a row that is already deleted by another process, instead of just ignoring the deleted row?

Is there any available option in ADO.NET to ignore this fact?

I am using SQLCommandBuilder with ConflictOption set to ConflictOption.OverwriteChanges.

Jonathan Leffler
  • 730,956
  • 141
  • 904
  • 1,278
Rookian
  • 19,841
  • 28
  • 110
  • 180

1 Answers1

1

You can use the DataViewRowState enumeration to select only the modified rows.

var rowsToUpdate =
            dataTable.Select(null, null, DataViewRowState.ModifiedOriginal);
Greg B
  • 14,597
  • 18
  • 87
  • 141
Dutch Nico
  • 250
  • 2
  • 8