I have a varchar column in a table which containts special characters like $,#,*,/ and so on, any number of times and anywhere in the column values. I need to populate this column into another table by removing all such special characters and retain only alaphanumeric characters. Can anyone suggest how this can be done by using a normal sql update query instead of stored procedure?
I remember Oracle has such mechanism to replace or decode the characters. I hope the functions TRANSLATE and DECODE would solve the purpose.As far as Teradata is concerned, we do not have any such mechanism.But we can use other alternatives to do so. For eg:- you can use the UDF's to process the Character fields .
Vinay, I've tried using all the said functions. But they are good only to locate and eliminate individual character. But I'm not sure how many such characters are there in the column. So, the no.of iterations of the same logic is indeterminate. That's what I find undo-able about this with a single query. I know this can be done using a stored procedure, but again, even I'm trying to work out an alternative.