Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Reformatting Phone Numbers
Message
 
 
To
11/11/2002 16:09:28
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00721264
Message ID:
00721269
Views:
12
>I have 8,000 records in a table. I would like to remove any characters such as(,),- that are currently there separating the area code from the number, being left with just the numbers.
>Example:
>Current: (800)555-5555
>I would like to see: 8885555555
>Then I can set the format and input mask properties for future entries.
>
>Thanks

The following code will remove all non-digit characters from the phone filed.
SELECT mytable
REPLACE ALL PhoneNum WITH CHRTRAN(PhoneNum, CHRTRAN(PhoneNum , "01234567890", ""), "")
--sb--
Previous
Reply
Map
View

Click here to load this message in the networking platform