Skip to Content
avatar image
Former Member

Hi all..very urgent..error fixing..full marks wud be given for the answers.

Hi gurus,i having trouble in executing the transaction VL10.

the procedure is as follows.

1.Enter the transaction VL10

2.Select Sales orders Tab

Enter sales document number 16283319 to 16283320

Remaining all fields should be blank

3.Click on Execute Icon.

4.Selected two Sales Documents.

5.Clickd on Back ground icon.

6.Error i am getting is OBJECT REQUESTED IS CURRENTLY LOCKED BY USER PSREDDY.

Can anybody help me with this..very urgent and full marks wud be given.

Its not the problem with the user.PSREDDY..have already checked dat in SM12.

its problem with ENQUEUE function module as per the client..can any body help me in resolving this issuee

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

9 Answers

  • avatar image
    Former Member
    Nov 16, 2007 at 08:49 AM

    Some one else is already opened the sales document no in editable mode and thats why you are getting such error. If that person come out from editable mode for that sales order no then you will not get such error.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 08:57 AM

    Hi Sahil,

    Go to SM04 ..

    place cursor on USER and click on sessions..check all users in same way...then you'll come to know who is actually using these documents... either you can intimate them to close session OR you can close that session ..then continue with your job..

    Hope it is help ful for you....

    Message was edited by:

    Perez C

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 08:59 AM

    Hi

    write a DEQUQUE fun module for that and see

    see the lock objects doc and do accordingly

    also take the help of a basis consultant in this regard

    Lock objects are use in SAP to avoid the inconsistancy at the time of data is being insert/change into database.

    SAP Provide three type of Lock objects.

    - Read Lock(Shared Locked)

    protects read access to an object. The read lock allows other transactions read access but not write access to

    the locked area of the table

    - Write Lock(exclusive lock)

    protects write access to an object. The write lock allows other transactions neither read nor write access to

    the locked area of the table.

    - Enhanced write lock (exclusive lock without cumulating)

    works like a write lock except that the enhanced write lock also protects from further accesses from the

    same transaction.

    You can create a lock on a object of SAP thorugh transaction SE11 and enter any meaningful name start with EZ Example EZTEST_LOCK.

    Use: you can see in almost all transaction when you are open an object in Change mode SAP could not allow to any other user to open the same object in change mode.

    Example: in HR when we are enter a personal number in master data maintainance screen SAP can't allow to any other user to use same personal number for changes.

    Technicaly:

    When you create a lock object System automatically creat two function module.

    1. ENQUEUE_<Lockobject name>. to insert the object in a queue.

    2. DEQUEUE_<Lockobject name>. To remove the object is being queued through above FM.

    You have to use these function module in your program.

    check this link for example.

    http://help.sap.com/saphelp_nw04s/helpdata/en/cf/21eea5446011d189700000e8322d00/content.htm

    tables:vbak.

    call function 'ENQUEUE_EZLOCK3'

    exporting

    mode_vbak = 'E'

    mandt = sy-mandt

    vbeln = vbak-vbeln

    • X_VBELN = ' '

    • _SCOPE = '2'

    • _WAIT = ' '

    • _COLLECT = ' '

    • EXCEPTIONS

    • FOREIGN_LOCK = 1

    • SYSTEM_FAILURE = 2

    • OTHERS = 3

    .

    if sy-subrc <> 0.

    • MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO

    • WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.

    endif.

    Normally ABAPers will create the Lock objects, because we know when to lock and how to lock and where to lock the Object then after completing our updations we unlock the Objects in the Tables

    http://help.sap.com/saphelp_nw04s/helpdata/en/cf/21eea5446011d189700000e8322d00/content.htm

    purpose: If multiple user try to access a database object, inconsistency may occer. To avoid that inconsistency and to let multiple user give the accessibility of the database objects the locking mechanism is used.

    Steps: first we create a loc object in se11 . Suppose for a table mara. It will create two functional module.:

    1. enque_lockobject

    1. deque_lockobject

    before updating any table first we lock the table by calling enque_lockobject fm and then after updating we release the lock by deque_lockobject.

    http://help.sap.com/saphelp_nw04/helpdata/en/cf/21eea5446011d189700000e8322d00/content.htm

    GO TO SE11

    Select the radio button "Lock object"..

    Give the name starts with EZ or EY..

    Example: EYTEST

    Press Create button..

    Give the short description..

    Example: Lock object for table ZTABLE..

    In the tables tab..Give the table name..

    Example: ZTABLE

    Save and generate..

    Your lock object is now created..You can see the LOCK MODULES..

    In the menu ..GOTO -> LOCK MODULES..There you can see the ENQUEUE and DEQUEUE function

    Lock objects:

    http://www.sap-img.com/abap/type-and-uses-of-lock-objects-in-sap.htm

    http://help.sap.com/saphelp_nw04s/helpdata/en/cf/21eea5446011d189700000e8322d00/content.htm

    Match Code Objects:

    http://help.sap.com/saphelp_nw2004s/helpdata/en/41/f6b237fec48c67e10000009b38f8cf/content.htm

    http://searchsap.techtarget.com/tip/0,289483,sid21_gci553386,00.html

    See this link:

    http://www.sap-img.com/abap/type-and-uses-of-lock-objects-in-sap.htm

    Check these links -

    lock-objects

    lock-objects

    lock-objects

    Regards

    Anji

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 09:09 AM

    hi sahil,

    your sales order has been processed by user PSREDDY u can contact basis person for get detail of user or u can see lock entry by transaction SM12 it is SAP standard feature that noone can update a database table while other user is updating the same.

    Rewards if helpful.

    Regards

    Gagan

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 07:57 PM

    Transaction SM12 will display User Locks. Check this before executing your program.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 08:17 PM

    Check note 339742.

    Rob

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 09:42 PM

    Run it at for ground to see witch object is locked.

    Some time code in user exits may do this

    (like to try change the delivery or the material that used in delivery on save user exit)

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 09:52 PM

    Check out in SM12 and SM04. If those are clear then logout your system and login again.

    Thanks,

    Srinivas

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 16, 2007 at 10:55 PM

    Sahil,

    is your problem solved?

    if not try to logoff from SAP system and login again, if still it says locked then PSREDDY must be editing that SO. then go to SM04 and kill that transaction.

    Regards,

    Satish

    Add comment
    10|10000 characters needed characters exceeded