03-30-2015 11:10 AM
When would you want to use cumulative locking - i.e. placing a lock on a set of records and then placing another lock on the same records, in the same program, before you've released the first lock?
All the textbooks tell you how to do this, but none of them tell you why you might want to do so.
Thanks,
Chris.
03-30-2015 2:34 PM
From SAP help:
Exclusive locks can be requested several times from the same transaction and are processed successively. In contrast, exclusive but not cumulative locks can be called only once from the same transaction. Each further lock request will be rejected.
Rob
03-30-2015 3:44 PM
Hi Rob,
Yes, but where might such locking be used? What business or data processing scenario? I notice this question has been asked on several occasions on this forum, but no one seems to have a clue about the answer. Anyone?
03-30-2015 5:19 PM
Hi Tim,
in many situations, you must make sure that an object is locked before you change it. A Calling program/function may have set the lock already, so you set it again anyway. Then it is cumulative.
Right, you may also check for lock first and lock only if not already locked, but who does?
Regards, Clemens
03-31-2015 1:20 PM