Removing weird characters from a column During selection.

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
iwin
Premium Member
Premium Member
Posts: 99
Joined: Mon Apr 11, 2005 9:20 pm

Removing weird characters from a column During selection.

Post by iwin »

Hi ,
I am trying to select a column which has weird character at the end of data. Can anyone help me how to select only the corrected data.

Ex: 1234@

Thanks Inadvance
I_Server_Whale
Premium Member
Premium Member
Posts: 1255
Joined: Wed Feb 02, 2005 11:54 am
Location: United States of America

Post by I_Server_Whale »

iwin,

What is the length of the column? How many weird characters are in the end? Can you give some more examples of your data.

I'm assuming according to the example given by you. You should be able get rid of the '@' by selecting

InLink.Incolumn[1,4]

Thanks,
Naveen.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
rwierdsm
Premium Member
Premium Member
Posts: 209
Joined: Fri Jan 09, 2004 1:14 pm
Location: Toronto, Canada
Contact:

Re: Removing weird characters from a column During selection

Post by rwierdsm »

iwin,

You could try filtering all characters that have a value of greater than ASCII (x7F). Those are generally considered the 'special' characters that can cause grief in downstream processing.

http://en.wikipedia.org/wiki/Ascii

Rob W.
Rob Wierdsma
Toronto, Canada
bartonbishop.com
iwin
Premium Member
Premium Member
Posts: 99
Joined: Mon Apr 11, 2005 9:20 pm

Re: Removing weird characters from a column During selection

Post by iwin »

rwierdsm wrote:iwin,

You could try filtering all characters that have a value of greater than ASCII (x7F). Those are generally considered the 'special' characters that can cause grief in downstream processing.

http://en.wikipedia.org/wiki/Ascii

Rob W.
Hi rwierdsm,
Thanks for your advise. Can you please explain me how to code it to filter the characters.

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

Post by ray.wurlod »

There are many possible solutions depending on your definition of "corrected". What characters do you want to preserve, and what characters do you want to discard?
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