Content Management and Capture

Content Management and Capture

Come for answers. Stay for best practices. All we’re missing is you.

 View Only
Expand all | Collapse all

How can I find the "internal user ID" assigned to a given user by Process Engine?

  • 1.  How can I find the "internal user ID" assigned to a given user by Process Engine?

    Posted Fri July 15, 2022 07:38 PM

    Please see this link: https://www.ibm.com/support/pages/node/241341

    I'm only using this as an example to show what I'm referring to.

    My question is how I can convert from the user's name to the internal ID assigned to each user. I need to query for WorkObjects that are assigned to the logged-in user, but I don't know what value I should specify in my query for F_BoundUser.



    #FileNet
    #Support
    #SupportMigration


  • 2.  RE: How can I find the "internal user ID" assigned to a given user by Process Engine?

    Posted Fri July 15, 2022 07:39 PM

    Here's another example support page that talks about this internal ID. Again, this is only to show what I'm referring to by "internal ID": https://www.ibm.com/support/pages/node/126055



    #FileNet
    #Support
    #SupportMigration


  • 3.  RE: How can I find the "internal user ID" assigned to a given user by Process Engine?

    Posted Fri July 15, 2022 08:15 PM

    Hi Steve,

    You can convert a username to a userid using vwtool convert command:

    <vwtool::1>convert

    Convert:

    t - Time number to string

    s - String to time number

    e - Error tuple to three part

    p - Three part error to error tuple

    l - Log event type number to string

    i - User id to user name

    n - User name to user id

    g - Convert guid string

    If you need any additional user info, you can use the vwtool env view command:

    <vwtool::1>env

    View/ Statistic/ Inconsistency/ Cache/ Notification/ Remove environment records (CR=v,s,i,c,n,r): v

    Cached or persistent environment records (CR=c, p): p

    Name, '*' for all env records: p8admin

    Name: p8admin

    Realm: dc=vmmrealm

    DisplayName:p8admin

    DN: uid=p8admin,o=defaultwimfilebasedrealm

    Id: 50

    SID: S-1-98-842282037-912470115-1684169261-859057505-1630351926-761672248-1631139384-825570356-943273271-67108864

    WebAppl: 10

    DB Time stamp: 07/15/22 10:26 AM

    Developing a Java app, you can use the VWSession.convertUserNameToId method.

    https://www.ibm.com/docs/en/filenet-p8-platform/5.5.x?topic=development-process-java-api-reference

    public int convertUserNameToId(java.lang.String aUserName) throws VWException

    Converts a user name in three-part format (name:domain:organization) to a user ID. This method invokes a call to the Process Engine if there has been no previous server call to get user names. If the system does not find the user name, internally the method performs an additional RPC to retrieve an updated list of user names.

    Hope that helps!

    --Joseph



    #FileNet
    #Support
    #SupportMigration


  • 4.  RE: How can I find the "internal user ID" assigned to a given user by Process Engine?

    Posted Wed July 27, 2022 12:52 PM

    Thank Joe, that's exactly what I needed!


    For others reading this, I also found this useful when I needed the ID for the logged-in user:

    vwSession.fetchCurrentUserInfo().getNamePx().getUserId();




    #FileNet
    #Support
    #SupportMigration