Thursday, June 2, 2011

Oracle regexp_replace function

I needed to remove non-ASCII characters from an Oracle column and this regular expression did the trick nicely:

 

update TABLE set COLUMN = regexp_replace( COLUMN,'[^a-z,_, ,A-Z,0-9,@,&,$,:,.,%,'']','');

 

 

No comments: