I have some examples on phone number, as shown below:
0810-093-485-58
0811.4845.5677
0812 567 6788 2
08138475967079/0813845765998
0814749345875 NEW
64739845985
0815756867967 (G) / 022 845 769
00816956865090
0817637698578
I tried to use replace and regexp, as follows:
select replace (number, '','') as phone_number
from details
where number not regexp '[[:punct:] A-Za-z]' and number not regexp '^ [1-9]'
These syntaxs applied only result:
0817637698578
My point here is I want to clean up those punctuation, spaces, and the letter contained to be:
081009348558
081148455677
08125676788 2
08138475967079
0814749345875
0815756867967
0816956865090
0817637698578
So, the result is not only one, but all the phone numbers, just non-numeric is being cleared. What about the syntax? Please help. Thank you.