Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
ssnaik84
Starting Member
15 Posts |
Posted - 2008-07-08 : 01:20:51
|
| hi..I want to build a function which can remove all characters other than digits [0-9] in a string.e.g.phone(020) 333-333-4444 or 020-333-333-4444 or 020 (3)33 44444 whatever would be the combination..Result should be: 0203333334444Can I use regular expression with string functions?since, i have to run it on a particular column of a table.Thanks. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
|
|
VGuyz
Posting Yak Master
121 Posts |
Posted - 2008-07-08 : 02:55:43
|
| Hi friend ..Just check thisselect replace(replace(replace(replace('(020) 333-333-4444 ','-',''),'(',''),')',''),' ','') |
 |
|
|
|
|
|