Automic Workload Automation

 View Only
Expand all | Collapse all

Append the report of the same JOBS executed many times

  • 1.  Append the report of the same JOBS executed many times

    Posted Jan 25, 2023 11:58 AM
    Hello, 

    I need to append the report of a JOBS.
    It is launched with the command UC_ACTIVATED_OBJECT from a different JOBS and it is executed many times.
    I need to append each report in a single file/report and to send it via e_mail at the end of this cycle.
    I know there is the possibility to use PRE_PROCESS_REPORT and WRITE_PROCESS but I don't know how to insert them in the 2 JOBS if this is the correct procedure of course.

    Thank you for your help in advance

    Stefano


  • 2.  RE: Append the report of the same JOBS executed many times

    Posted Jan 26, 2023 07:18 AM
    Edited by Bernhard Flegel Jan 26, 2023 08:03 AM
    Hello Stefano,
    one possible way is:

    You put the following lines in the postscript-tab of your many times executed job:

    :set &hnd# = prep_process_report()
    :SET &RET# = WRITE_PROCESS(&HND#,"/<path/to/your/file>/appended_report.txt",&$AGENT#, <login-object>,APPEND)

    On each run the report will be appended to the given file. At the end of your cycle you send the file via mail.


    Best regards
    Bernhard