I haven't had to do a whole lot of scripting myself so I'm not exactly too familiar with this and not sure if this can be done. Referring to DE 11.3.3 is there a end date time variable for a job? I'm seeing symbolic variables for the WOB start date and time but what about for the end date time? If not is there a way to create one?
my thoughts is a WOB variable is resolved when a job submit so it would be unable to resolve an end time when the job submits.
same applies to DATE or TIME
%APPL._SDATE = scheduled date of application
%APPL._ADATE = actual start date of application
%APPL._RDATE = runtime start date of application
%WOB._RDATE = runtime start date of WOB
Hey Sharon! Hope you have been doing well sine CA World. Your statement does make sense but I will try to pursue Dons comments below and see if I can somewhere with that. What we have now is when a job fails it triggers an event which ultimately creates a ticket with the failed job information but the time that is in the ticket is the start time of the failed job and not the end time, probably for the reason that you stated. Thanks for the information!
I am doing well, hope all is well with you too.
What happens when your alert it triggered now?
We do trigger alerts when our jobs fail. We created an alert that is added was added to all applications - notications - alert for failed, overdue and suberror. So when a job fails the alert this alert is triggered, the alert runs this java script and triggers another application called ZZAUTOCUT, the script zzautocut runs pulls in all these as arguments.
execTrigger("ALERT.ZZAUTOCUT","add"," ","NOHOLD","%WOB._tag","SubCount-%(WOB._subcount)--%(APPL._name).%(APPL._gen).%(WOB._name).%(WOB._qualifier) --%(WOB._state)","%(WOB._LDATE) %WOB._LTIME","%WOB._agent" );
APPL._genAPPL._truserWOB._nameWOB._qualifierWOB._agentWOB._stateWOB._statusWOB._typeWOB._jobnoWOB._cmpcWOB._RHH WOB._RMN WOB._RYEAR WOB._RMMM WOB._RDDWOB._tag
we are doing very similar things. Yes we get time of failure by using WOB._LDATE and WOB._LTIME instead of RHH, RMN, RYEAR and RMMM and RDD.
start Sat 6 Jan 2018 06:10:05 CST
end Sat 6 Jan 2018 06:10:06 CST
autocut script passes
"IM48562" "SubCount-3--AA_SEC.1022.PAAU600111.TERM_JOB --FAILED" "Saturday 6th Jan 2018 06.10.06" "UXPRD710"
Thanks Sharon for sharing this, come work for us!
I would be warmer if I came to work with you!
Thanks for your info too, I realized we could add APPL._truser to our messages.
Have a Good Day
Depending on what you are trying to accomplish, one of the options below may work for you.
Set up an alert when the job completes. It will trigger an event. Variables can be used to get the jobname and much more. The built in variables APPL._ADATE and APPL._TIME can be used to get the current time. They will be within a second or two of the actual job end time. These variables can also be used to create a user defined variable with the end time.
Query the database for the job start and end time. With the variables from the ALERT the exact job information can be retrieved. This can be done using a script/job.
Let me know if I missed the boat.
Thank you Don for the information. I believe the first example is worth pursuing but is there somewhere in the manuals that help to explain how to do this or something I can refer to? If nothing readily available than I will turn to researching it and seeing if I can teach myself how to define it. Appreciate the time.