CA Scheduler has three components for sending emails: email groups, email definitions and email templates.
An email group is a list of one to one hundred (100) email addresses stored in the CA Scheduler database. You define the email group with an arbitrary name, such as "PAYROLLGROUP."
For example:
DEFINE EGROUP NAME='PAYROLLGROUP',ADDR='
[email protected]
[email protected]'
Note that email addresses may contain upper and lower case letters.
Any number of email groups may be defined.
An email definition identifies the jobs or schedules for which an email should be sent, and under what conditions it should be sent. The email definition is also given an arbitrary name and stored in the CA Scheduler database.
For example:
DEFINE EMAIL NAME='PAYROLLDEF',EGROUP='PAYROLLGROUP',
JOB='*',JNO='*',STATION='40',SCHEDULE='PAYROLL',
FAIL=YES,ABEND=YES,LATE=YES
This email definition causes an email to be sent to all of the addresses in the email group called "PAYROLLGROUP" when any CPU job in the "PAYROLL" schedule gets a bad return code, abends or is marked late.
The job name, JNO, station and schedule fields all accept wildcard characters "*" and "?", where "*" matches any number of characters (including zero) and "?" matches any one non-blank character.
Any number of email definitions may be defined. Multiple email definitions may reference the same jobs and schedules and may use the same email group.
Email templates contain the actual text of the email. Email templates are stored in a partitioned dataset allocated to the CA Scheduler started task. Default templates are provided to generate emails in HTML format. You may add as many additional email templates as needed.
For example, your company may have offices in other countries where a different language is spoken. You may create email templates for these other languages, then define email groups and definitions to use the new templates. (The email definition contains optional fields allowing you to specify the template name to be used.)
Of course, CA Scheduler has online screens in addition to the batch commands shown above to define and maintain email groups and definitions.