REGEX_REPLACE does not work as expected in oracle 10g

I am using the method REGEX_REPLACE

in Oracle 10g, but it doesn't replace strings.

Here's what I'm (unsuccessfully) trying:

Select REGEX_REPLACE('Mathew, Sajan K ext (E IT S US 1)','\\([^\\)]+\\)','') "REGEXP_REPLACE"

      

+1


source to share


1 answer


Try the following:

Select REGEX_REPLACE('Mathew, Sajan K ext (E IT S US 1)','\([^\)]+\)','') "REGEXP_REPLACE"

      



Note that I just removed the extra escape characters \

, some languages ​​seem to require doubling the escape code and some don't.

Ref: Oracle SQL Database Reference REGEX_REPLACE

+2


source







All Articles