SAS Data Integration Studio, DataFlux Data Management Studio, SAS/ACCESS, SAS Data Loader for Hadoop and others

How to pass the job name via email in DI?

Accepted Solution Solved
Reply
Contributor
Posts: 58
Accepted Solution

How to pass the job name via email in DI?

I can send email via the Job status handling.

If an error occurs in the job, I need to pass the job name in the message of the email.

How to do it within the handling status of a job?

Searching on google, I see that there is a variable called ETLS_JOBNAME.

And in the code generated by the DI, the following command sends the message of the email:

      data _null_;

                       file sendMail;

                       dttm = put(datetime(),nldatm.);

                       put dttm "&message.";

        run;


Accepted Solutions
Solution
‎07-19-2014 06:38 AM
Respected Advisor
Posts: 3,890

Re: How to pass the job name via email in DI?

&ETLS_JOBNAME gets defined as global macro variable. It should therefore be possible to pass this macro variable as message value.

Capture.PNG

This then generates code as below:

      %etls_sendEmail

         (address = something,

          Message = &ETLS_JOBNAME);

View solution in original post


All Replies
SAS Employee
Posts: 33

Re: How to pass the job name via email in DI?

Hi David,

I don't know if you determined a resoluotion for yourself on this question or not. If not, I recommend that you reach out to SAS Technical Support and open a track to have this question addressed.

Regards,

Mike F.

Solution
‎07-19-2014 06:38 AM
Respected Advisor
Posts: 3,890

Re: How to pass the job name via email in DI?

&ETLS_JOBNAME gets defined as global macro variable. It should therefore be possible to pass this macro variable as message value.

Capture.PNG

This then generates code as below:

      %etls_sendEmail

         (address = something,

          Message = &ETLS_JOBNAME);

☑ This topic is SOLVED.

Need further help from the community? Please ask a new question.

Discussion stats
  • 2 replies
  • 360 views
  • 1 like
  • 3 in conversation