|
FOROS PROFESIONALES WINDEV, WEBDEV y WINDEV Mobile |
| | | | | |
| Data Currently Locked by another user Error!!!! |
| Iniciado por guest, 04,jul. 2017 08:35 - 1 respuesta |
| |
| | | |
|
| |
| Publicado el 04,julio 2017 - 08:35 |
Hello Everyone;
Wish all a great day!!!
I am running over a scenario and kindly requesting help from my fellow Forum Mates. In my project over a process to avoid data during middle of entering something like in a Invoice Billing Window i have set up two nodes- One at starting and other at the end if the chain breaks before reaching the end node i have made some codes to roll back the entire process again back to original state. In all my projects this works perfect but over a mass user project i get back this error. Could anyone help me out with this error. SCREENS attached.
This is the inline code:
HTransactionStart(gsDbConnetion) WHEN EXCEPTION IN
HTransactionEnd(gsDbConnetion) DO //Roll back HTransactionCancel(gsDbConnetion) Error("Save has been failed") END |
| |
| |
| | | |
|
| | |
| |
| Publicado el 04,julio 2017 - 12:40 |
Hi Amal, It is really difficult from your post to see what is happening ...
Here is how I GENERALLY do it - when using a HFSQL C/S database: 1.The code is from a window where "Independent HFSQL context" is CHECKED. This is VERY IMPORTANT
2. Basic type of code .... p_sErrorMessage is string ="" e_bTransaction is boolean=False HOnError("*",hErrAll,"") IF HTransactionStart()=False THEN p_sErrorMessage="problem starting the transaction ..." ELSE // call a procedure to do updates, inserts etc .. // this procedure returns TRUE or FALSE e_bTransaction=YourProcedure(...) IF e_bTransaction=FALSE p_sErrorMessage="transaction canceled ..." HTransactionCancel() ELSE HTransactionEnd() END END
/////////////////////////////////////////////////////////// If your code - that I cannot see - is NOT working in a SPECIFIC client, it could be that a transaction is STILL running or you have a "corrupt transaction" (due to a power failure on the server?). You can check this in your HFSQL control center ... //////////////////////////////////////////////////////////
Steven Sitas www.alpha360.biz |
| |
| |
| | | |
|
| | | | |
| | |
| | |
| |
|
|
|