Olgun_Onur_Ozmen

SYS_STATE_JP_ACTIVE check flow name with alias

Discussion created by Olgun_Onur_Ozmen on Dec 5, 2017
Latest reply on Dec 5, 2017 by Wolfgang_Brueckler_1288
Hi Everyone,

I am activating the workflow named(VIT_PEAK.INTEGRATION.TEMPLATE_FLOW) in script object(JOB1) via activate_uc_object function with alias.
I want to check status of workflow via another job (CHECK_JOB1) ,if a workflow has already been activated case but SYS_STATE_JP_ACTIVE function does not see object with alias.


function see that --> VIT_PEAK.INTEGRATION.TEMPLATE_FLOW
i want check status of --> VIT_JOBP.VIT.PEAK.INTEGRATION.TEMPLATE_FLOW.&AEJOBNAME#.&FLOW_RUNID#

how can i figure out this case ? 

JOB1

:Pset &AEJOBNAME#=STR_UC(&AEJOBNAME#) :put_att ARCHIVE_KEY1="&AEJOBNAME#" :put_att ARCHIVE_KEY2="&FLOW_RUNID#" :SET &ACT#= ACTIVATE_UC_OBJECT("VIT_PEAK.INTEGRATION.TEMPLATE_FLOW",,,,,PASS_VALUES,"VIT_QUEUE","VIT_JOBP.VIT.PEAK.INTEGRATION.TEMPLATE_FLOW.&AEJOBNAME#.&FLOW_RUNID#")

CHECK_JOB1

:SET &JOBP#="VIT_JOBP.VIT.PEAK.INTEGRATION.TEMPLATE_FLOW.&AEJOBNAME#.&FLOW_RUNID#" :p JOBP:&JOBP# :wait 5 :SET &REPEAT#="Y" :WHILE &REPEAT#="Y" :set &jobactive#=SYS_STATE_JP_ACTIVE("&JOBP#") :p jobactivemi:&jobactive# :IF &jobactive#<>"N" :    p jobactive:&jobactive# | jobp active on activation tab will check again! :    set &REPEAT#="Y" :  else :    p jobactive:&jobactive# | jobp not a activation tab! :    set &REPEAT#="N" :ENDIF :ENDWHILE

Thanks.

Outcomes