/* release.p
*/
define variable r as integer no-undo.
find first customer no-lock. /* record scope is now the procedure block */
r = recid( customer ).
find _lock no-lock where _lock-recid = r no-error.
display
available customer
_lock-flags when available _lock
"NL" when not available _lock @ _lock-flags
with
frame pre-trx
title "Pre TRX"
no-labels
row 1
column 1
.
do transaction:
find current customer exclusive-lock.
update name.
release customer.
find _lock no-lock where _lock-recid = r no-error.
display
available customer
_lock-flags when available _lock
"NL" when not available _lock @ _lock-flags
with
frame in-trx
title "In TRX"
no-labels
row 1
column 25
.
end.
/* release customer. */
find _lock no-lock where _lock-recid = r no-error.
display
available customer
_lock-flags when available _lock
"NL" when not available _lock @ _lock-flags
with
frame post-trx
title "Post TRX"
no-labels
row 1
column 50
.
pause.