select '11dd$%example@sqldat.com' as input, regexp_replace('11dd$%example@sqldat.com', '[^[:alnum:]]') as output
from dual
;
INPUT OUTPUT
------------ --------
11dd$%example@sqldat.com 11dde11h
[:alnum:] सभी अक्षरों (मानक ASCII अक्षर, निचला और ऊपरी मामला) और सभी अंकों के लिए आशुलिपि है। [^ ... ] मतलब ... . को छोड़कर सब कुछ . तो, यह अक्षरों और अंकों को छोड़कर सब कुछ बदल देगा... कुछ भी नहीं (चूंकि हमने REGEXP_REPLACE को तीसरा तर्क नहीं दिया)।
संपादित करें :ओपी ने प्रश्न में दूसरा भाग जोड़ा।
यदि असाइनमेंट केवल सभी अल्फा-न्यूमेरिक वर्णों को हटाने के लिए है, और बाकी सब कुछ रखने के लिए, बस ^ हटा दें रेगुलर एक्सप्रेशन से.
select '11dd$%example@sqldat.com' as input, regexp_replace('11dd$%example@sqldat.com', '[[:alnum:]]') as output
from dual
;
INPUT OUTPUT
------------ ------
11dd$%example@sqldat.com $%example@sqldat.com