6 Replies Latest reply: Apr 15, 2013 7:14 PM by Adeesh Fulay RSS

    Report's output emailing


      OEM 11.1

      I'm struggling to figure out how to get an email sent from OEM GC that has the output of OEM job?

      select sysdate date from dual ---- script for the job.

      Job is Scheduled once a day - 07:00

      Is there a way to have the output of a job (not the status of the job execution) to be emailed?
      (we have many email notifications for rules in effect)

      Thx for your suggestions.
        • 1. Re: Report's output emailing
          Adeesh Fulay
          The only way to get access to job output is either via alert notifications or via emcli verbs. For the latter, you write a custom script that will run emcli and email the job output. Good luck!

          • 2. Re: Report's output emailing

            Alert notifications are for the outcome of the job, not the output of it.

            Unless there is a way I'm not aware of ?

            • 3. Re: Report's output emailing
              Adeesh Fulay
              I don't have a EM 11g environment to verify this, but in EM 12c you can customize the email format to include the attribute 'EXECUTION_OUTPUT' to include the job output in alert email. Please verify if the same attribute is available in EM 11g.
              • 4. Re: Report's output emailing
                Why don't you create a report to get the result of the job? In the Schedule tab of "Create Report Definition" you have the option (E-mail report) to send the report to whoever you want. This combined with the example here (Report All Oracle User Accounts Through OEM Grid Control)
                http://darrylgriffiths.blogspot.nl/2011/08/report-all-oracle-user-accounts-through.html will do the trick.

                • 5. Re: Report's output emailing
                  Not sure where to start creating the report (creating jobs - ok):

                  "We just need to write a report to pull out the details.

                  Create a new report called "LIST_USER_ACCOUNT_DETAILS".
                  On the "General" tab, select the "Use the specified target" option and enter the hostname of your OEM Grid Control repository server (DB server).
                  Select the "Run report using target privileges of the report owner (SYSMAN)" tick box.
                  On the "Elements" tab, add a "Table from SQL" item and then set the header, then paste in the statement below:...."

                  Where to start?

                  • 6. Re: Report's output emailing
                    Adeesh Fulay
                    Try this tutorial: