I'm having a few problems with DataStage parameters and am wondering if anyone can help.
I'm now used to setting job parameters from a sequential file using a pre job routine. In this way we can set parameters from an external source without having to manually type anything in....great for batch jobs.
What we would like to do, but are unable at present, is to set parameters at the controlling sequence level. This would mean that we could set the parameters once, and then run multiple jobs within a sequence that would then all use the parameters set at the higher level. This would then avoid having to set the parameters once for each individual job.
Can anyone help with this? Would be much appreciated.
Parameters in Datastage Sequences
Moderators: chulett, rschirm, roy
Hi,
Well if you want to use sequence GUI jobs you simply need to put all the relevant parameters in the sequnce job itself and pass the relevant parameters to each job/routine activity you have in the sequence; wrap it in some DS basic controll job that gets the parameters list of your sequence job and assigns the values from the data you retrieved from your parametes file.
If you ment DS basic sequence to automatically assign values, the logic is similar, execpt you'll need some GoSubs to perform parameters assignment for each one, actually I think this is one of the course exersises when learning DS if my memory serves me.
if your not familiar with how to get the parameters list take a look in the DS Help for the DSGetJobInfo routine and such.
bare in mind as Ray often reminds us all that checking for a successfull DSSetParam call to ensure it was ok foreach parameter you set in each job.
IHTH
Well if you want to use sequence GUI jobs you simply need to put all the relevant parameters in the sequnce job itself and pass the relevant parameters to each job/routine activity you have in the sequence; wrap it in some DS basic controll job that gets the parameters list of your sequence job and assigns the values from the data you retrieved from your parametes file.
If you ment DS basic sequence to automatically assign values, the logic is similar, execpt you'll need some GoSubs to perform parameters assignment for each one, actually I think this is one of the course exersises when learning DS if my memory serves me.
if your not familiar with how to get the parameters list take a look in the DS Help for the DSGetJobInfo routine and such.
bare in mind as Ray often reminds us all that checking for a successfull DSSetParam call to ensure it was ok foreach parameter you set in each job.
IHTH
Roy R.
Time is money but when you don't have money time is all you can afford.
Search before posting:)
Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
Time is money but when you don't have money time is all you can afford.
Search before posting:)
Join the DataStagers team effort at:
http://www.worldcommunitygrid.org
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
No less important, if you "roll your own", is checking that DSGetParamInfo calls were successful.roy wrote:checking for a successful DSSetParam call to ensure it was ok for each parameter you set in each job.
Build in insurance against future developers, who obviously know/care less than you (always a safe assumption), changing the parameter names in jobs from which your code obtains them.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Got a solution for us in the end, but not by the same meathod. Instead we just ran a routine in the sequence. We then opened the job properties of the jobs where we wanted to use the parameter, and then clicked on the 'insert parameter value' on the 'job' tab. Scrolling down, we saw that you can link the parameter for the job to the output of the routine. Good enough for us for this instance.....
But please make sure that you are not using sequence stage. This stage will not probagate the return values of the routine activity.
Go through the post
viewtopic.php?p=101868#101868
Arun
Go through the post
viewtopic.php?p=101868#101868
Arun
Thats probably saved us some problems. Thanks!Vishvas wrote:But please make sure that you are not using sequence stage. This stage will not probagate the return values of the routine activity.
Go through the post
viewtopic.php?p=101868#101868
Arun
Keep in mind that fact that the problem mentioned in the other post is specific to the 7.x version and that propagation of Routine return values beyond Sequence stages works just fine in 6.x.
Now the question is... will this still be the case when you decide it's time to upgrade?
Now the question is... will this still be the case when you decide it's time to upgrade?
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers