Board index » delphi » EDBEngineError- "...another user changed the record"

EDBEngineError- "...another user changed the record"

Hi,

I'm communicating with a SQLServer on our network through ODBC. Sometimes
when I try
to make Edit on a record, using TTable in Delphi Prof. 3.02, then I get the
exception
"Project ... raised exception class EDBEngineError with message 'Couldn't
perform the edit
because another user changed the record'.

Even if the record was changed by another user should I be able to changed
it.

Is there something that I have missed?

Thanks

Bj?rn M?ller

COMBRA Industriteknik AB
Sweden

 

Re:EDBEngineError- "...another user changed the record"


Bjorn

This is a perennial problem.  Firstly, check the Update property of the
TQuery (or TTable) you are using.  You can change that to one of three
values.  You'll probably find that UpWhereChanged will suit you.

Your problem is most likely caused by one of three things:

1.  Another user (or connection, or part of your app) did change the
underlying record.
2.  You're using a field with a default value which is updated on the
server every time the record is being edited (ie a TimeStamp field)
3.  Your table is corrupted (happened to us only yesterday - but it's
*very* rare)

Derek Davidson
Author of DK's Audit Components
Get a FREE copy from my web site at :
http://freespace.{*word*269}.net/d.davidson

(Remove the x to EMail me : der...@mksoft.com)

Re:EDBEngineError- "...another user changed the record"


Derek,

What is the course of action in the case of a table corruption?

Quote
>3.  Your table is corrupted (happened to us only yesterday - but it's
>*very* rare)

>Derek Davidson

Re:EDBEngineError- "...another user changed the record"


David

We dropped the table, recreated it and then all ran fine.  You may find
that a database unload, stripping out the stuff related to the table,
dropping the table and then performing a read of the table (and data)
would also work.  We weren't too bothered about the data as we were in
a testing phase.

Derek Davidson
Get a FREE copy of DK's Audit Components for Delphi from my web site:
http://freespace.{*word*269}.net/d.davidson
Now Includes INFOPOWER Derived components and a demo

(Remove the x to EMail me : der...@mksoft.com)

Other Threads