2016 Mar 15 4:59 PM
My requirement is to delete a user session by the lock entry.
So assuming I have one lock entry in SM12 that I want to get rid of.
Instead of just deleting this lock entry I want to delete the session that causes this lock entry.
I know one connection is the User. However if the User has two sessions I would only want to delete that session that causes the lock and therefore automatically also get rid of the lock entry.
Any help much appreciated.
BR
My requirement is to delete a user session by the lock entry.
So assuming I have one lock entry in SM12 that I want to get rid of.
Instead of just deleting this lock entry I want to delete the session that causes this lock entry.
I know one connection is the User. However if the User has two sessions I would only want to delete that session that causes the lock and therefore automatically also get rid of the lock entry.
Any help much appreciated.
BR
2016 Mar 16 10:31 AM
That's a hard solution for the user which is currently creating a 1000 lines document...
In SM12 (or FM ENQUE_READ) did you identifyt the id to use in
call function 'TH_DELETE_USER'
exporting
user = <lock>-bname
client = <lock>-mandt
tid = <lock>-tid
exceptions
authority_error = 1
others = 2.
As you are SAP employee, don't you know someone who could match parameters of system funcions C_ENQUEUE and ThUsrInfo parameters?
Regards,
Raymond
2016 Apr 22 2:06 PM
There is a way of finding a connection of session to lock entry.
The return table from FM 'th_show_usr_details' has an entry that looks something like this:
field = *].enq_info
value = '20170402XXXXXXXXXXXXXXX311XXXsuie.........................'
This entry can then be matched with the lock entry fields gusrvb or gusr.
This way you know if a lock entry belongs to a particular session.
Then via FM ENQUE_DELETE the lock entry can be deleted.
2016 Apr 22 3:49 PM
If I remember right, you can double-click the user in user overview SM04 and delete a specific session.Make sure it's the right session, make sure the last activity is quite some time ago. Try to read the user by phone, mail or so.
Best regards Clemens
| User | Count |
|---|---|
| 6 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |