Hi,
I have scenario where i need to read data from a table and if the table has data i need to write that data into a flat file and send an email with this flat file as an attachment.Can any one suggest me what is best way of approaching this scenario.
Sending an Email
Moderators: chulett, rschirm, roy
1. Write a job to spool the table to a file.
2a. Write Batch job to run job #1, then either issue a unix command to check the file for data (wc -l is a good choice), or use the DSGetLinkInfo API to query job #1 for the link row count to get the row count. If a non-zero value is found then either issue a unix mailx command or try to use the SDK supplied function for sending emails.
2b. Alternative, use a Sequencer to do all of 2a.
2a. Write Batch job to run job #1, then either issue a unix command to check the file for data (wc -l is a good choice), or use the DSGetLinkInfo API to query job #1 for the link row count to get the row count. If a non-zero value is found then either issue a unix mailx command or try to use the SDK supplied function for sending emails.
2b. Alternative, use a Sequencer to do all of 2a.
Kenneth Bland
Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle
Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle