stage variable: Check for string and output row

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
rajeevm
Participant
Posts: 135
Joined: Sun Jan 22, 2006 10:44 am

stage variable: Check for string and output row

Post by rajeevm »

Hi

I have a requirement that to check for the string in a column and return that entire row to the output . Suppose I have 'true' in the column then return that else return the row which has 'false' . I am trying to do this in stage variable not sure the approach is correct .

I have total 6 columns

Please help me out how to write it as a stage variable I really appreciate your help

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

Post by chulett »

We'll need a better explanation than that to really be able to help, I'm afraid. Can you post some actual examples of the strings you need to search? For example, I'm unclear if what you are looking for is a total match or a substring match. Also unclear if you need to check all six at once and return one of the six... or something else.
-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 »

Allow me to re-parse your stated requirement and then offer my "solution".

(If column = 'true' Or column = 'false') Then transfer row to output.

Solution: transfer all rows to output.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply