Page 1 of 1

Pass parameter value file in Job sequence loop

Posted: Tue May 17, 2011 2:30 am
by le thuong
I have a loop in a Job sequence calling an elementary job N times. A parameter set is defined with N value files (each value file containing 3 parameters).
How can I specify in the Job sequence to pass value file 1 during call 1, value file 2 during call 2, etc...

Posted: Tue May 17, 2011 6:41 am
by chulett
Set it up in a delimited list or a dynamic array and then leverage the Start Loop's "loop counter" to pass the correct value each iteration.

Posted: Tue May 17, 2011 8:17 am
by le thuong
chulett wrote:Set it up in a delimited list or a dynamic array and then leverage the Start Loop's "loop counter" to pass the correct value each iteration.
Thank you Craig. I see how to pass the loop counter as parameter from the sequence job to the called job, but I don't see how to pass the value file name (name 1 for iteration 1, name 2 for iteration 2, etc...).

Posted: Tue May 17, 2011 9:01 am
by chulett
This post might help.

Posted: Wed May 18, 2011 2:05 am
by blewip
Is the problem actually passing the details of which value file to use in the sequence?

In the sequence parameters you can hard code it to any of the values. However the sequence doesn't seem to let you define a variable that will contain which value file to use?

The only option I can think of is to call the job using a script, and to pass is the variable this way. Which is a bit clunky

Posted: Wed May 18, 2011 2:36 am
by le thuong
The sequence job (with a loop) does not allow passing value file N (of a parameter set) at iteration N (of the loop) to a called job.

We have developed a workaround solution:
- Sequence job with a loop calling Job A, then Job B.
- Job A has 1 parameter (Iteration number), reads a sequential file where each record corresponds to a value file of our initial Parameter set and writes 1 record (depending on the Iteration number) to another Parameter set (which is also a sequential file).
- Job B will make use of this new parameter set, populated with new values on each iteration.

Posted: Wed May 18, 2011 6:41 am
by chulett
I would imagine that, with a little thought, you could use a UserVariables stage to build a delimited list of parameter values and then refer to it with the loop counter.