My phone number field has rows with different formatting.
e.g.
12824673737
and
(510) 890-9699
How can I force all the phone numbers to be of one format: namely, a 10 digit number without any punctuation in between
My phone number field has rows with different formatting.
e.g.
12824673737
and
(510) 890-9699
How can I force all the phone numbers to be of one format: namely, a 10 digit number without any punctuation in between
Best answer by W_Vann_Hall
@W_Vann_Hall, when using a formula, would the Concatenate option work too? Something like this:
CONCATENATE("(",LEFT(PHONE,3),") “,MID(PHONE,4,3),”-",RIGHT(PHONE,4))
Regards,
André
Yes, that would work to add punctuation to an unformatted phone number (assuming the user wanted US-style phone punctuation). Personally, I’d do it using the '&' form of concatenation, simply because I always get confused parsing an explicit CONCATENATE() function — but I know people (many of whom spreadsheet programming wizards) who are the complete opposite, and can’t stand all those ampersands. :winking_face: (You’d still need to strip a leading '1', if it existed.)
The OP, though, wanted to strip punctuation from a punctuated number — or, at least, I think he did. (…) Yes, I checked: He wanted an unpunctuated 10-digit number. That’s why I sent him through the nested SUBSTITUTE()s, peeling back the number.
There’s actually a much easier way to convert phone fields to a consistent 10-digit number — one I didn’t think of at first, because it takes advantage of an Airtable behavior I strongly believe in urgent need of correction: Namely, the way VALUE() [usually] merely ignores non-numeric characters, rather than returning an error. So
MOD(
VALUE(
Phone
),
10000000000
)
will also convert a column of mixed formatted 10-digit phone numbers and unformatted 11-digit numbers into a consistent column of unformatted 10-digit numbers.
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.