0
votes

I am trying to extract numbers from a string comprises of alpha and special characters like Green - 100% Green - 90% Red - 0% Red - 25% Yellow - 50% Yellow - 75% I tried REGEXP_REPLACE (COLUMN_NAME, '[[:alpha:]]') but this will leave - and %. Should i add two more REGEXP to replace the - and %? Or is there an effective way to do it in one function?

Also in another problem i need to identify the double quotes in a string and replace with two times of double quotes and finally wrap entire string in double quotes eg: Example" should be converted to "Example""" Sam"ple should be converted to "Sam""ple"

Appreciate your solution