Page 1 of 1

CheckRowVersion

Posted: Fri 07 Aug 2009 07:10
by jlund
Hi

I am having a problem when i update a record usin SQL server.

Though i have set CheckRowVersion to False, the row verion is still checked, and I get an error saying that the record has been changed by another user, and in DBmonitor, I can see that a select statement is run just before the update statement.

Furthermore, I can see that a Start is run just before, and a commit just after the select..update in DBmonitor - is this normal behavior ?

This is also true when I use MySQL

TIA Jens Lund

Posted: Fri 07 Aug 2009 07:37
by Plash
You should set the LockMode property of TUniTable to lmNone. Otherwise TUniTable locks the record and compares values of all data fields to the values from the database before update. If some field was changed in the database, the error is raised.

Thank

Posted: Fri 07 Aug 2009 08:18
by jlund
That worked !

Thanks
/Jens