pass parameter to DSSendmail Subroutine

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
Das
Participant
Posts: 87
Joined: Tue Oct 24, 2006 9:58 pm
Location: india

pass parameter to DSSendmail Subroutine

Post by Das »

Hi

How can i pass parameter (from ,to,subject,body) to DSSendmail Subroutine
Any body can give the code

Thanks in advance
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

The code is already provided, in a routine called DSSendMailTester (under Routines\Built-In\Utilities in your Repository).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Das
Participant
Posts: 87
Joined: Tue Oct 24, 2006 9:58 pm
Location: india

call DSSendMailTester from control job

Post by Das »

ray.wurlod wrote:The code is already provided, in a routine called DSSendMailTester (under Routines\Built-In\Utilities in your Repository). ...
Thanks

Can i directly call this DSSendMailTester routine from a control job
in datastage 6,
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

You are meant to Test the routine directly in the Manager to 'run' it, you don't really need a control job.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Das
Participant
Posts: 87
Joined: Tue Oct 24, 2006 9:58 pm
Location: india

Post by Das »

Hi

i want to run the routine from the controll job by passing some values as arguments .is it possible
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

You would need an appropriate DEFFUN declaration. Why not use it as a prototype for your own control job in which you call DSSendMail? If it's you calling it, you can supply whatever values you like for its arguments, whether job parameters or random strings!
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Das
Participant
Posts: 87
Joined: Tue Oct 24, 2006 9:58 pm
Location: india

Post by Das »

[quote="ray.wurlod"]You would need an appropriate DEFFUN declaration. Why not use it as a prototype for your own control job in which you call DSSendMail? If it's you calling it, you can supply whatever values you like ...[/q

Thanks .Can u give the code here?
sb_akarmarkar
Participant
Posts: 232
Joined: Fri Sep 30, 2005 4:52 am
Contact:

Post by sb_akarmarkar »

Das,

Everything is given in help document.. You just need to click...

DSSendMail("From:me@here\nTo:You@there\nSubject:Hi ya\nBody:Line1\nLine2")


I think this can help.

___________
Anupam
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Das wrote:Can u give the code here?
The code is already in DSSendMailTester routine.

And my name is not "u".
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply