Hi All,
Can you help answering this question bellowing?
Are there any ‘roll back’ mechanism in C/SIDE?
For Example: one transaction insert into G/L Entry table but in the inserting process, some entry line already, some entry line not yet and the power, network,… turn-off suddenly. How is about this transaction? Are they roll back or missing some entry line?
Thanks,
Thang
0
Comments
So if in the middle of a posting, your client-computer crashes, the DB rolls back the transaction automatically.
If your are writing to the DB, and at a certain moment, you notice (with C/AL code) that there is something wrong, just give an ERROR or FIELDERROR and Navision rolls back the transaction.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
i have a problem with the 'Roll back' when i m using 3 'CodeUnit'. For example, i m using the "Item Jnl.-Post Batch" CodeUnit to post some item entries, but before, i'm calling a second CodeUnit to post some resource entries using the "Res. Jnl.-Post Batch". :whistle:
So my problem is: when there is an error in posting the item entries, then the system must cancel the posting of the resource entries Already validated ; This is not the case !!! ](*,)
Thankssss
NAVISION CONSULTANT
TUNISIA
You can add a function in the codeunit that receives a boolean : IblnSkipCOMMIT. This is then saved in a global.
Then the codeunit.RUN must be called to post the batch.
In the codeunit, everywhere you find a COMMIT, you must change it to The negative of this is that the transaction becomes longer. So if it is possible to divide the transactions and create something to recover from an ERROR in the second part, this would be even better.
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!
Thank you very much!
Thang