How to limit the number of output files to a COPY stage

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
dsean
Participant
Posts: 22
Joined: Thu Feb 09, 2006 12:52 pm

How to limit the number of output files to a COPY stage

Post by dsean »

Hi,
I am using the Enterprise edition for the first time and I want to know how to send dynamically the number of output files that we want to create or copy using the COPY stage in Enterprise edition. I did a search for this but did not find anything about this. Any help can be greatly appreciated.


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

Post by ray.wurlod »

Copy stage does not create output files. The Copy stage creates as many copies of its input stream as there are output links from the stage. This is done in memory - no files are involved.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
dsean
Participant
Posts: 22
Joined: Thu Feb 09, 2006 12:52 pm

Post by dsean »

Ray,
Thanks for your reply. may be the question that I posted is not clear.

Lets say I have a Copy stage with one input link and 4 output links . Now without changing the job design , Can I limit the number of output copies to 3 during runtime from the COPY stage??

Once again, I appreciate your help.

Thanks in advance,
Sean
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Not that I am aware of.
-craig

"You can never have too many knives" -- Logan Nine Fingers
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

More clearly, No.

You can do achieve what you describe using a Filter stage or a Transformer stage. You may be able to do it with a Switch stage (if the condition for output link selection is based on values in the data).

If a Copy stage has N output links it will always generate N streams of output (for N >= 0).
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Thanks for the more clearly... was pretty sure but not 100% Wurlod proof sure. :wink:
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply