Skip to Content
avatar image
Former Member

Get real userid from a WDA application that uses service account

A WDA application runs under a service account. How to get the real userid (i mean, the human user)?

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    Nov 29, 2011 at 04:55 PM

    When running as a service user, the application is anonymous. In other words no user authentication or identification takes place. What kind of "real" user information would you expect to get? Are you running in the NetWeaver Portal? Or standalone? What informaiton are you looking for? Of course nothing within ABAP is going to be able to "see" the real user since the user session is running as the service account. Why exactly are you using a service user anyway? There are only very few instances where service users in WDA applications wouldn't be a violation of your license agreement.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Thomas,

      Thank you for your time on my issue.

      The WDA application is run in NetWeaver Portal. I need log his/her operation along with his/her userid when someone logs on to the portal and run this application. It would be very easy if the WDA app is not run with a service user since we can use sy-uname. However, the WDA app is run under a service user we cannot use sy-uname here. Then my question is, how can I know who logged on to portal and ran this app?

  • avatar image
    Former Member
    Nov 29, 2011 at 07:33 PM

    The solution can be found at

    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/008fc414-997f-2e10-3899-fd895ec8eb5e

    Thank you guys for your time!

    Add comment
    10|10000 characters needed characters exceeded