cancel
Showing results for 
Search instead for 
Did you mean: 

Regarding Locks

former_member186775
Contributor
0 Kudos

locked objects are not displayed in lock entries (ie)SM12?

I did all the locking procedure correct but these locks are not

diplayed in SM12 (i.e)Lock entries??

Accepted Solutions (1)

Accepted Solutions (1)

JPReyes
Active Contributor
0 Kudos

SM12 display the Database locks... what locking procedure are you talking about?

Regards

Juan

Former Member
0 Kudos

Oops Juan,

Sm12 shows enque locks. DB01 is for databse locks. Just an input.

Regards.

Ruchit.

Answers (3)

Answers (3)

former_member186775
Contributor
0 Kudos

Any updations are welcome

Former Member
0 Kudos

The common mistake everybody does

Please put client as *

username as *

and execute

Probably u will find the lock entry

thank You

Haroon

Former Member
0 Kudos

Hi,

When a lock request comes from a user for a table, first the lock entry is made in SM12. The lock entry is made only when no other lock entries are present for that particular table.

To execute the lock request ( or the lock entry in SM12 ) a corresponding lock object is defined in ABAP dictionary. The lock object is nothing but, it contains the details on which table to be locked.

So when corresponding lock object is created, it has a series of lock modes assigned to them like, Write locks (X), exclusive write locks (E), Shared locks (S). The lock modes are shown SM12.

THis is definite indication that lock objects for defined for lock entries in SM12.

Former Member
0 Kudos

SM12 displays SAP transactional locks (managed by enque service). There are different from database locks.SAP does not use DB locks at all.

Transactional lock means that if you start a SAP transaction for data change appropriate lock key for edited object is creatred wchich can be observerd in SM12.Lock depends on object edited.

Lock is removed after SAP transaction is completed and data is updated by update processes in database (you can see status of update processes in SM12).

Former Member
0 Kudos

One of the most common mistakes you hear when teaching is that SAP does not use database locks, SAP does use database locks. SAP uses its own locking mechanism to provide more enhanced locking features, as described in these posts, for SAP transactions.

The reason you have transaction DB01 is to monitor the database locks which are created when the work process does the actual write/delete on the database. DB01 allows you to see these locks and also allows you to identify deadlocks which can occur, as we have just witnessed on our systems over the weekend.