In ORACLE databases, how do I find regular expressions for non-Chinese characters except numbers and letters? oracle Regular Expressions
Recently, a project has the following requirements: in ORACLE databases, regular expressions for non-Chinese characters except numbers and letters are obtained.
If the following fields exist, replace all the characters except letters, numbers, and Chinese characters with null.
'Asdfsad ,,;)()! @ 123234 # $ % ^ & * (my w is e? Chinese .. /\ []: '"One person'
Final value: asdfsad123234 I am a Chinese user
Select FN_REG_REPLACEOTHER ('asdfsad ,,;)()! @ # $ % ^ & * (I am? Chinese .. /\ []: '"One person",' required regular expression, ') from dual;
Thank you. Do not post the following answers:
(\ S) | (\,) | (\,) | (\.) | (\.) | (\ :) | (\;) | (\ () | (\)) | (\ () | (\ ') | (\ '') | (\") | (\ [) | (\] | (\!) | (\!) | (\ @) | (\ #) | (\ %) | (\ ^) | (\ &) | (\ *) | (\ $) | (\ $) | (\/) | (\?) | (\?))
------ Solution --------------------
Select regexp_replace ('asdfsad ,,;)()! @ 123234 # $ % ^ & * (my w is e? Chinese .. /\ []: '"One person'
, '[[: Punct:] | [: blank:] | [: space:] | [: cntrl:]', '')
From dual
;
REGEXP_REPLACE ('asdfsad ,,;)
-----------------------------
Asdfsad123234 I w is e Chinese
Well, the content of this article ends here, hoping to be useful to everyone.