rangebob Posted January 9, 2003 Posted January 9, 2003 I have 600 records that I've imported and the telephone numbers have no - in them. How do I add the dash into the phone number?
andygaunt Posted January 9, 2003 Posted January 9, 2003 Are your numbers just 5551234567 If so then create a calculation field (FormatNumber, result of text) "(" & Left(Phone Number,3) & ") " & Middle(Phone Number, 4, 3) & "-" & Right(Phone Number, 4) This will return (555) 123-4567 HTH
Lee Smith Posted January 9, 2003 Posted January 9, 2003 I would use a calculation field to format it. Take a look at the file "Phone Format" available at http://www.datatude.net/ go to Tips and Downloads. HTH
jasonwood Posted January 9, 2003 Posted January 9, 2003 Just to clarify, the above responses won't really do what you have asked, because they involve a separate field for display. However, this is a better way to go. Set the new calculation field so that it does not allow entry into field, then place it overtop the existing phone field. You will see the formatted field, but when you click, the cursor goes into the field below. Then make it a rule that staff never enter phone numbers with any formatting, and you ensure that all phone numbers will be formatted the same way on the screen.
andygaunt Posted January 9, 2003 Posted January 9, 2003 Or, use the calculation and do a calculated replace on the data instead. Then the phone number field (which must be a text field) will have the valid format) Be careful when using the replace function. Try on a copy of the database first or on a small (1 or two records) set of data to make sure the result is what you expect.
rangebob Posted January 10, 2003 Author Posted January 10, 2003 Thanks for all the replys. You are all too helpful.
Recommended Posts
This topic is 8058 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now