I have some Semaphores implemented through MySQL, I am converting from Zeos and ADO to DBEXPress but it isn't working with drivber from Devart. Other connections need to see the semaphores on READ UNCOMMITED connections, but the semaphores don't appear... Ex.:
User on Station 1:
Starts Semaphore as:
//
...
TD.TransactionID := 1;
TD.IsolationLevel := xilCustom;
MyQuery.Text := 'SET SESSION TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;';
MyQuery.ExecSQL;
MyConn.StartTransaction(TD);
MyQuery.SQL.Text := 'insert into MySemaphoreTable (MyValue) values (''ak2'');';
MyQuery.ExecSQL;
....
//The rollback happens after 10 min, never occurs commit, or can occur automatic rollback too because lost connectios. Other connections READ COMMITED never see the 'ak2'. in this time other users must see the 'ak2' through READ UNCOMMITED especilized connections
//
Other user on Station 2:
TD.TransactionID := 1;
TD.IsolationLevel := xilCustom;
MyQuery.Text := 'SET SESSION TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;';
MyQuery.ExecSQL;
MyConn.StartTransaction(TD);
MyQuery.SQL.Text := 'Select * from MySemaphoreTable where MyValue = ''ak2'';'
MyQuery.Open; //==> The problem is here, the query must to return 1 record but is empty ...
On DBExpress from RadStudio or ADO works fine.
Codes on Delphi 2010 and MySQL 5.1 and 5.5
Roberto Novakosky