Concurrency Error:0 Records Affected

  • Thread starter Thread starter Bob Morris
  • Start date Start date
B

Bob Morris

I am continually receiving this error when I am trying to add a new record
through the SqlDataAdaptor. I am working on a single user machine so there
is no question of this being a real concurrency error. What I do have to do
is to call BeginEdit() and EndEdit() several times during the generation of
the new record to force calculated row expressions to update and I have an
idea it's something to do with that.

Looking back over previous post headers on the block I see that this isn't
exactly a new problem. Unfortunately the messages themselves have been
expired.

In my ideal world I would be able to turn off ALL data checking by the
Adaptor / Dataset and leave it to the SQL sp's and triggers that I have in
place. (That's ALL, not just EnforceConstraints=false)!

Any ideas please?

Bob
 
Check for SET NOCOUNT ON

If it's set to ON, Set it to OFF where you would like to see the number of
rows affected
 
I did finally sort this one out, by comparing the various row versions. How
there can be an "original" version of a new record escapes me but there it
was.

This wasn't even getting as far as SqlServer, it was the DataSet trying to
be "helpful".

Thanks anyway.

Bob
 
Back
Top