Automic Workload Automation

Expand all | Collapse all

Groovy Report on jobs by platform

  • 1.  Groovy Report on jobs by platform

    Posted 11-14-2018 09:45 AM

    I would like to write a Groovy report that identifies all objects that have a PLATFORM z/OS for AE_DEV clients 1000, 2000 and 3000, as well as AE_PRD client 4000 -- as shown.  

     



  • 2.  Re: Groovy Report on jobs by platform

    Broadcom Employee
    Posted 11-26-2018 01:22 PM

    Hello!

     

    Thank you for submitting your question to the community! I'm no Groovy expert but it looks like you are simply asking for the SQL statement which would then be put into Groovy to retrieve this information. I was able to put a SQL statement which pulls this information from our Oracle database below.

     

    The JBA table contains the column "JBA_HOSTATTRTYPE" which is where the values in the platform column are coming from for the jobs. For reference you can find this type of information in our DB Schema documentation online below:

     

    AE Database Scheme for Version 12.2 (Step 020) 

     

    Since the JBA table doesn't contain information on the Objects including the client number we also need to inner join with the OH table comparing the OH_IDNR and JBA_OH_IDNR to match. While we would highly recommend reaching out to our professional services team for additional support, you can use the below SQL as a guide to get what you are looking for.

     

    Example to pull all Z/OS Platform Job Names from Clients 1000, 2000 and 3000

     

     

    SELECT OH_NAME FROM OH
    INNER JOIN JBA on OH.OH_IDNR = JBA.JBA_OH_IDNR
    WHERE JBA.JBA_HOSTATTRTYPE = 'Z/OS' AND (OH.OH_CLIENT = '1000' OR OH.OH_CLIENT = '2000' OR OH.OH_CLIENT = '3000')

     

     

    Hope this helps!

    Andrew