This row has been removed from a table and does not have any data. BeginEdit() will allow creation

  • Thread starter Thread starter Scott Baker
  • Start date Start date
S

Scott Baker

I receive this message when I try to execute a valid delete command against
a dataset for which I have marked a row as Deleted. I have been struggling
with this for a couple of days, and every bit of the documentation say that
it should work.

The sql is generated with an OleDbCommandBuilder object and populated using
the original values of the columns in the row to delete (like this:)

System.Guid linkToID = (System.Guid) curLinkRow[0]["LinkToID",
DataRowVersion.Original];
..
..
..
objectObjectsAdapter.DeleteCommand.Parameters["@p3"].Value = linkToID;


Anyone found a way around this?

Scott
 
Was in the subject line. The error is

This row has been removed from a table and does not have any data.
BeginEdit() will allow creation of new data in this row.


Miha Markic said:
Hi Scott,

And the error is?

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com

Scott Baker said:
I receive this message when I try to execute a valid delete command against
a dataset for which I have marked a row as Deleted. I have been struggling
with this for a couple of days, and every bit of the documentation say that
it should work.

The sql is generated with an OleDbCommandBuilder object and populated using
the original values of the columns in the row to delete (like this:)

System.Guid linkToID = (System.Guid) curLinkRow[0]["LinkToID",
DataRowVersion.Original];
.
.
.
objectObjectsAdapter.DeleteCommand.Parameters["@p3"].Value = linkToID;


Anyone found a way around this?

Scott
 
The moment that the update is called, it throws a general exception, and
that is the exception.Message value.

Miha Markic said:
Ah, blind me.
When do you receive the error? At Update?

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com

Scott Baker said:
Was in the subject line. The error is

This row has been removed from a table and does not have any data.
BeginEdit() will allow creation of new data in this row.


Miha Markic said:
Hi Scott,

And the error is?

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com

I receive this message when I try to execute a valid delete command
against
a dataset for which I have marked a row as Deleted. I have been
struggling
with this for a couple of days, and every bit of the documentation say
that
it should work.

The sql is generated with an OleDbCommandBuilder object and populated
using
the original values of the columns in the row to delete (like this:)

System.Guid linkToID = (System.Guid) curLinkRow[0]["LinkToID",
DataRowVersion.Original];
.
.
.
objectObjectsAdapter.DeleteCommand.Parameters["@p3"].Value = linkToID;


Anyone found a way around this?

Scott
 
Ah, blind me.
When do you receive the error? At Update?

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com

Scott Baker said:
Was in the subject line. The error is

This row has been removed from a table and does not have any data.
BeginEdit() will allow creation of new data in this row.


Miha Markic said:
Hi Scott,

And the error is?

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com

Scott Baker said:
I receive this message when I try to execute a valid delete command against
a dataset for which I have marked a row as Deleted. I have been struggling
with this for a couple of days, and every bit of the documentation say that
it should work.

The sql is generated with an OleDbCommandBuilder object and populated using
the original values of the columns in the row to delete (like this:)

System.Guid linkToID = (System.Guid) curLinkRow[0]["LinkToID",
DataRowVersion.Original];
.
.
.
objectObjectsAdapter.DeleteCommand.Parameters["@p3"].Value = linkToID;


Anyone found a way around this?

Scott
 
Hi Scott,

It seems to me that delete command (parameters probably) are reading from
Current version instead of original.
Can you inspect the delete command parameters?
 
Back
Top