Clarity

  • 1.  UserID in GELSCRIPT

    Posted Aug 09, 2016 06:21 AM

    Hello

    How can I do to get, in the GELSCRIPT of a process launched manually, the user ID of the submitter ?

    Thank you for your answers



  • 2.  Re: UserID in GELSCRIPT

    Posted Aug 09, 2016 07:01 AM

    You'll need to use the id of the running GEL process to read that off the database table I think;

     

    Some information here ; Gel script: How to get the resource ID of the currently logged in user?



  • 3.  Re: UserID in GELSCRIPT

    Posted Aug 09, 2016 07:02 AM

    You can use the below query to get the process initiator,

     

    SELECT usr.first_name, usr.last_name, usr.user_name, runprc.*
      FROM bpm_run_processes runprc INNER JOIN cmn_sec_users usr on usr.id = runprc.initiated_by
      WHERE  runprc.id = ${gel_processInstanceId}
    


  • 4.  Re: UserID in GELSCRIPT

    Posted Aug 09, 2016 07:30 AM

    Thank you for this very helpful response



  • 5.  Re: UserID in GELSCRIPT
    Best Answer

    Posted Aug 09, 2016 07:05 AM

    You can refer undocumented variable gel_processInitiator

    or

    using documented features, fetch from process instance id

    SELECT

         INITIATED_BY

    FROM

         BPM_RUN_PROCESSES

    WHERE

         ID= ${gel_processInstanceId}



  • 6.  Re: UserID in GELSCRIPT

    Posted Aug 09, 2016 07:29 AM

    Thank you for this very helpful response