Automic Workload Automation

 View Only
  • 1.  Send status of the workflows via email

    Posted Jan 08, 2020 08:02 AM
    Hi ALL, 

    i want to send daily the status of the "blocked" workflows via email.
    i have try it with the AE DB Reporting Tool and revision report but i get only a list with "ended" workflows. 


    How can i get or read the information like object name, title, start time, end time and runtime of the blocked jobs? 
    Maybe with SQL? Do you have any idea? 


    Thanks in advance. 

    Best regards
    Salih


  • 2.  RE: Send status of the workflows via email

    Posted Jan 09, 2020 03:15 AM
    Hi

    are you talking from the Workflows that are currently blocked?
    Otherwise you won't get much output because the Stati of a workflow during execution are not logged by default.

    Example:
    Workflow starts at 07:00 
    at 07:10 a job fails, WF gets blocked
    at 07:25 ops staff restarts the job, WF continues running
    07:30 WF is done, Status ENDED ok

    after 07:30
    If you check the WF status its ENDED_OK

    You will see the status "BLOCKED" only between 07:10 and 07:25 when the WF is blocked.

    In addition to that The Block state is a state of the workflow that a failed job could lead to but does not necessarily lead to - depending on the WF setting (dependencies).

    So your request is kind of tricky and not easy to fulfill.

    => I personally would use an SQL of all Jobs that did not end ENDED_OK and collect their parent if its a Workflow. Its not 100% your request but I think quite close to it :-)

    cheers, Wolfgang

    ------------------------------
    Support Info:
    if you are using one of the latest version of UC4 / AWA / One Automation please get in contact with Support to open a ticket.
    Otherwise update/upgrade your system and check if the problem still exists.
    ------------------------------



  • 3.  RE: Send status of the workflows via email

    Posted Jan 09, 2020 04:18 AM
    Hi, 

    i want to send a list via email of the blocked workflows during the defined timeframe for example between 0.00 and 06.00 (actual date).

    The job will be run at 6.10 and if a workflow is currently blocked so i will know the following information:
    start time, 
    object name

    So i need only the currently blocked workflows. 

    Do you have an example of the SQL statements? 
    => I personally would use an SQL of all Jobs that did not end ENDED_OK and collect their parent if its a Workflow. Its not 100% your request but I think quite close to it :-)
    Best regards
    Salih


  • 4.  RE: Send status of the workflows via email

    Posted Jan 09, 2020 04:51 AM
    Hi

    you can use this one - shows all Workflows currently in blocked state

    select EH_ALIAS,EH_AH_IDNR as "RunId", EH_STARTTIME, EH_EJPP_LNR as "Object No", eh_status from eh
    where eh_client = [your client Number]
    and eh_otype = 'JOBP'
    and eh_status in (1560)

    change client number to your needs.
    You can add more stati if you want...

    cheers, Wolfgang

    ------------------------------
    Support Info:
    if you are using one of the latest version of UC4 / AWA / One Automation please get in contact with Support to open a ticket.
    Otherwise update/upgrade your system and check if the problem still exists.
    ------------------------------



  • 5.  RE: Send status of the workflows via email
    Best Answer

    Posted Jan 09, 2020 04:52 AM
    BTW: List of Status codes is here:.
    https://docs.automic.com/documentation/webhelp/english/AA/12.3/DOCU/12.3/Automic%20Automation%20Guides/help.htm#AWA/Executions/ReturnCodesExec.htm?Highlight=status%20codes

    ------------------------------
    Support Info:
    if you are using one of the latest version of UC4 / AWA / One Automation please get in contact with Support to open a ticket.
    Otherwise update/upgrade your system and check if the problem still exists.
    ------------------------------



  • 6.  RE: Send status of the workflows via email

    Posted Jan 28, 2020 05:52 AM
    Hi Wolfgang, 

    thanks for your help! it works!
    I will also get a list from the active workflows. So i changed the status code:

    the result is: 

    How can i get the start time of the workflow? I can only see the start date.


    Best regards
    Salih