Skip to Content
avatar image
Former Member

Email Notification after Job run

Hi everybody,

I want to setup an email notification at the end of a job run.

The job is an update run from our Activate Directory and checks if there are some changes to do.

At the end or after this job I would like to send an email to the admin that the job successfully run and what the job did.

How could I setup this?

At the moment I tried to use a SQL statement to table MC_LOGS within a script called in the last pass of the job.

But I only get the information what to job do from the last run of the job and not from the current run.

Best regards & a happy new year, Anja

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Jan 05, 2010 at 10:00 AM

    Hi Anja

    Your last pass can only fetch information from the last run and not the current one because the Job is still running and the respective log is not yet written to the table.

    But maybe you could use the LogFile created then the Job finishes.

    I suppose you use the "LDAP (ADS) - Update All"- Job for LDAP-to-IC updates. This job writes a logfile to %$ddm.ddmpath% which you could send as mail attachment. Use the UpdateJob-"Event scheduling" button to run your SendMail-Job after every UpdateJob-completion.

    Another idea would be to use the SQL-View MCMV_JOBLOG which I think is the datasource of IC-JobLog. I suppose column "mcmv_data" stores the details.

    Hope I could help.

    BR

    Michael

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Use a "To Generic" and put your script into Source-> "Initialization script".

      As I think Shell execute is used for batch or executable files.

      And another hint: uncheck "This question is answered" cause it will attract more readers and perhaps better answers 😊

  • avatar image
    Former Member
    Jan 05, 2010 at 02:02 PM

    Hi Michael,

    that's a good hint. I try this way ... and maybe anybody would have another solution ...

    BR Anja

    Edited by: Anja Wagenbret on Jan 5, 2010 3:02 PM

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jan 26, 2010 at 02:28 AM

    Depends on how you are doing this.

    If it's a maintenance / recon job, you can add a pass with an email notification. There are examples if you use the pass wizard.

    Otherwise you can create a task that does this as well.

    basically the task will invoike the uSendSMTP function, it's well documented and easy to use.

    Regards,

    Matt

    Add comment
    10|10000 characters needed characters exceeded