Page 1 of 1

Removing Special Characters

Posted: Tue Sep 15, 2015 9:35 am
by sachinshankrath
Hello - Anyone worked on removing special characters coming from DB2 and Ms Sql Server databases? Basically the special character can be anything thats not an alphabet/number or anything thats not on the keyboard. How would I go about writing something in Datastage v8.7 Parallel that would parse an input string, accept only letters/numbers/any character found on the keyboard but convert everything else to spaces? Anything found on the keyboard such as !@#$%^....is acceptable because that can be easily removed later.

Posted: Tue Sep 15, 2015 9:42 am
by chulett
Do an exact search here for "double convert" where you provide a list of the characters you want to keep and everything else is removed from the string. One such example is here.

Removing Special Characters

Posted: Tue Sep 15, 2015 11:18 am
by sachinshankrath
THANK YOU! It seems to work and I hope it captures all special characters. Only time will tell....I will come back here if I face further problems.

Posted: Tue Sep 15, 2015 4:21 pm
by ray.wurlod
Is this what your customer wants? Are (some of) these special characters meaningful to them, for example accented alphabetic characters?