Hello, I've a problem with a multiuser application.
MyDac: 6.00.0.1 for Delphi XE
MySQL server version: 5.5.8
this is the scenario:
Pc A:
mytable.Edit;
Pc B:
mytable.Edit;
Here I expected an exception to be thrown,
so I can alert the user he can't editing that record at that time.
But, when the "Pc B" call mytable.Edit, the application hang until the "Pc A"
call post or commit. Also the OnEditError event is not fired.
this happens also into the mydac lock demo in the same way.
ps: Both Pc A and Pc B are connecting to mysql server with the same account and the table engine is InnoDB.
I hope you have some suggestion on this.
pessimistic lock hang
-
Valerio M.
- Posts: 4
- Joined: Sun 02 Jan 2011 14:41
pessimistic lock hang
Last edited by Valerio M. on Tue 04 Jan 2011 14:55, edited 1 time in total.
-
AndreyZ
-
Valerio M.
- Posts: 4
- Joined: Sun 02 Jan 2011 14:41
-
swierzbicki
- Posts: 451
- Joined: Wed 19 Jan 2005 09:59
-
Valerio M.
- Posts: 4
- Joined: Sun 02 Jan 2011 14:41
Right, I had already thought this.swierzbicki wrote:Hi,
Don't know if this is possible but before editing just test if the record is locked.just another question. there's a way to manually abort the "Pc B" edit command while it is waiting for inno db timeout?
But, I can't find any "mytable.TryEdit" or "mytable.isRecordLocked"
-
AndreyZ