Page 1 of 1

Need help on scenario

Posted: Fri Oct 07, 2011 3:40 pm
by james_b
Hi,

I want to make a simple job, I have Seq. file which has 10 records...Then I want to use Transformer stage and at the end o/p as another Seq file....

My requirement is Say I have :

1
2
3
4
5
6
7
8
9
10

as inpur records in seq file....


using transformer I need to replicate it 10 times in o/p......

so above records shousld come 10 times....but again i dont want to take out 10 outputs from transformer and then funnel it....

please guide me with some different logic....

Posted: Fri Oct 07, 2011 4:20 pm
by jwiles
You don't specify which version of DataStage you are using. For v8.5 and above, the looping capability of the Transformer is perfect for this. The Parallel Job Developer's Guide includes an example of just how to do this.

For versions 8.1 and below, either the option you wish to avoid (multiple output links and a funnel), a BuildOp or External Source/External Filter or maybe External Target would be the easiest methods. A short awk script called by External Source or External Filter could handle it.

Regards,

Posted: Mon Oct 10, 2011 3:30 am
by BI-RMA
Produce a cartesian product against input from a row-generator. Set the number of rows produced from the row-generator to any number of copies you like.

Posted: Mon Oct 10, 2011 5:40 am
by udayk_2007
you can use a copy stage to copy it to 10 different links and then put a funnel stage to combine them

Posted: Mon Oct 17, 2011 5:59 am
by deeplind07
you can also use a start loop and end loop stage and loop through your job 10 times