modify stage question

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
UCDI
Premium Member
Premium Member
Posts: 383
Joined: Mon Mar 21, 2016 2:00 pm

modify stage question

Post by UCDI »

I would like to have a really basic extraction job that can accept either * (or whatever code/string/anything) OR a list (col1, col2, col3) to feed to a modify stage. The idea is that the user could either extract specific columns (KEEP #param#) or all the columns (KEEP *).

The trouble is that KEEP * does not work. Nor does KEEP (space).
Nor does Specification = "empty string" or "space" ...

I guess what I am asking is, can I tell a modify stage to DO NOTHING via some specification magic command?

I know I can work around this with annoying amounts of complexity. My best take on it so far is to default parameter to #drop bogus#, use a transformer to add the bogus column, and if the parameter is overwritten it must contain "keep col1, col2, .." ... this works but its clunky.
ShaneMuir
Premium Member
Premium Member
Posts: 508
Joined: Tue Jun 15, 2004 5:00 am
Location: London

Post by ShaneMuir »

Parameterise the specification value and pass either your required keep statement or the phrase NOWARN
UCDI
Premium Member
Premium Member
Posts: 383
Joined: Mon Mar 21, 2016 2:00 pm

Post by UCDI »

That works, Thanks!!
Post Reply