Re: Row can not be located ... on Delete
- From: "Kevin Frevert" <kevin@xxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Mon, 28 Apr 2008 12:46:07 -0500
Eugene,
Inserting/Updating/Deleting data from a joined query can be tricky and
dangerous if it worked (ADO may delete records from all the joined tables).
I recommend using TClientDatasets
(TADODataSet->TDataSetProvider->TClientDataSet) to better control how the
underlying insert/update/delete scripts are built.
http://dn.codegear.com/article/22571
http://dn.codegear.com/article/20847
Good luck,
krf
"Eugene V. Goldberg" <egold@xxxxxxxxx> wrote in message
news:4815ab71$1@xxxxxxxxxxxxxxxxxxxxxxxxx
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.
.
- References:
- Row can not be located ... on Delete
- From: Eugene V. Goldberg
- Row can not be located ... on Delete
- Prev by Date: Moving Access queries from a DB to another
- Next by Date: Re: problem connecting to ADO programmatically
- Previous by thread: Row can not be located ... on Delete
- Next by thread: Re: Row can not be located ... on Delete
- Index(es):