So, what is the way to handle? For example, two operators work with the account through the special application. They haven't got straight acces to the database with help of SQL.
The first operator update the target account adding a few hundreds dollars. Therefore, record with this account are blocked.
The second operator tries to change value of this account. The appropriate command is transmitted to special procedure. The appropriate exception arise in this snippet of code because of target row is blocked by first operator transaction. Subsequently this exception is handled. For example, the procedure returns message to the second operator: "This account is being under change. Do you want to cancel your transaction or to wait a completion?"
Also, the procedure may returns user's name who change the target account.
* - quotation from Oracle Database Concepts
No comments:
Post a Comment