Skip to Content

Password resets in CUA via BAPI: How to specify the receiving client?


We are performing password resets via BAPI_USER_CHANGE in a CUA system. That works great to reset passwords in the prod environment as the CUA and the Prod clients are the same.

But now we need to specify whether the password change should be pushed to Dev, QA or both. Is it possible to specify the Receiving Client in a BAPI or FM?

From the GUI it's specify on the screen as per screenshot below. Here you can specify 1 or more of the clients where the password should be effected. We need to do something similar via a BAPI/FM to specify the target client. Is it possible?

NOTE: SCUM settings for Logon Data is set to Global.

untitled.png (112.9 kB)
Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    Posted on Nov 11, 2019 at 10:27 AM

    This should be working from CUA side for the subsystem specified (via triggering a USERCLONE IDoc):

    DATA method     TYPE bapimethod VALUE 'PWDINIT'.
    DATA logondata  TYPE bapilogond.
    logondata-codvn = abap_true.
    logondata-codvc = abap_true.
        username     = username
        method       = method
        subsystem    = subsystem
        logondata    = logondata
        wrong_system = 1
        OTHERS       = 2.
    IF sy-subrc <> 0.

    I don't belive the same can be done via BAPI_USER_CHANGE as there is no parameter for the receiver system.

    Edit: one drawback is that as far as I remember it does not work in the central system itself. Here e.g. SUSR_USER_PASSWORD_PUT can be used to deactivate the password locally and SUSR_USER_BUFFERS_TO_DB to save the results.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.