Well to attach sysout is quite easy in job definition.
Concerning logs, I will suggest following solution :
- create a script to read (with ctmlog) log information, and to send contains in a email.
- put that script somewhere on your CTM server
- add an SHOUT alias in your CTM Server as a Program updating SHOUT Table refering to your script (ex: SENDLOG)
- adding in plus after DO MAIL in your job, a DO SHOUT (notification) to SENDLOG
having orderid (%%ORDERID) in the message.
Script will receive ORDER ID information to read log with ctmlog, and will send an email with contains in the message.