Re: Row can not be located ... on Delete




Try setting the "Unique Table" property to the table you want to direct the
delete to.

ADODataSet.Properties['Unique Table'].Value:='Name of a table';

This property needs to be set after the dataset has opened. I normally set it
in the BeforeDelete event of the dataset.



D5, MS SQL 2000.

I have a dataset which joins 3 tables:

SELECT CIV_HEAD.*, CIV_PLAINTIFF.LAST_NAME,
CIV_PLAINTIFF.FIRST_NAME, CIV_PLAINTIFF.MIDDLE_NAME,
CIV_DEFENDANT.BUSINESS_NAME, CIV_DEFENDANT.LAST_NAME,
CIV_DEFENDANT.FIRST_NAME, CIV_DEFENDANT.MIDDLE_NAME
FROM CIV_HEAD LEFT JOIN CIV_PLAINTIFF ON CIV_HEAD.ID = CIV_PLAINTIFF.RID
LEFT JOIN CIV_DEFENDANT ON CIV_HEAD.ID = CIV_DEFENDANT.RID

All 3 tables have AutoInc ID field defined as primary key.

When i am trying to delete a record, it raises exception

Row cannot be located for updating. Some values may have been changed since
it was last read.

What am i missing? I expect Delete to remove the record from CIV_HEAD
table...

Thanx,
Eugene.


--
Brian Bushay (TeamB)
Bbushay@xxxxxxxxx
.