‎2008 Jul 09 6:58 AM
Hi Experts,
Is there any chance to release locks explicitly set by SAP itself?
That means when we r accessing database locks are set by SAP.i need to release these locks explicitly.
Thanks in Advance
‎2008 Jul 09 7:08 AM
Hi Siva,
The database objects or any programs can be released from locks by using transaction SM12
When u go to this transaction it lists you the objects being edited for a particular user given in the selection criteria. By selecting the objects in the list you can unlock the object.
Thanks,
Shailaja
‎2008 Jul 09 7:24 AM
‎2008 Jul 09 7:30 AM
Hi siva,
1. Go to SM12 transaction.
2. Click on List tab.
3. Then select the object whose lock u want to release.
4. then click on delete lock .
Lock will be relesed.
<REMOVED BY MODERATOR>
Thanks
Satyam
Edited by: Alvaro Tejada Galindo on Jul 9, 2008 12:01 PM
‎2008 Jul 09 7:35 AM
Hi Siva,
To release the locks, go for the transaction code. SM12.
This transaction code will display all the LOCK entries.
Select the required lock entry.
Delete the lock record, it will deleted and lock will be released.
OR
Using Programs:--
Go for SE11.....create one lock object with EY_ or EZ_ name convesion: eg EYLOCK1
Two function modules will be created
1) Enqueue (ENQUEUE_EYLOCK1 function module): to lock.
*2) Dequeue (DEQUEUE _EYLOCK1 function module)*: to release the lock.
call these function modules into your program and provide all the required parameters.
I think FIRST ONE will suit your requirement more.
With Regards,
Rupinder
‎2008 Jul 09 1:08 PM
Hi All,
Thanks for ur Replies.
But enduser don't want to use SM12 every time. Is there any chance of releasing locks during runtime?
Thanks,
‎2008 Jul 09 1:51 PM
HI,
Write a custom program which will execute periodically!!!
Fist check at Fm ENQUEUE_READ to read locked arguments. In this it will return the lock arguments based on user level.
Call function ENQUEUE_READ by passing client no .Now it will return the lock arguments. If you want base on user level then pass Guname = sy-uname into FM. While return, it will return the table name in GNAME.
By using this GNAME call ENQUEUE Fm dynamically.
I hope this solves your problem.
Rgds,
Raghu
‎2008 Jul 09 1:54 PM
Locks are set by SAP for a reason ie to try and ensure data consistency. End users should not be manually releasing locks set by SAP on a regular basis. Or at all, really.
‎2008 Jul 09 1:44 PM
Hi Siva.
GoTo->SE03(Transport Organizer Tools)->Request/Tasks->Unlock Objects.
Good Luck.
Harsh