Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Storing phone numbers
Message
From
20/10/2010 08:05:21
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
19/10/2010 12:43:21
Mike Cole
Yellow Lab Technologies
Stanley, Iowa, United States
General information
Forum:
Microsoft SQL Server
Category:
Database design
Miscellaneous
Thread ID:
01486152
Message ID:
01486290
Views:
50
>Hello,
>I am currently working on cleansing some horrific data. I need to store phone numbers (US and international). I usually use a 10 char field and strip out all special characters on the application side for US phone numbers. I've never worked with international phone numbers before. What's a good standard way of storing them?
>
>Thanks!

Which part is horrific? Having special characters in phone number field? IMHO a phone number field should be flexible and allow special characters. I hate database admins that thinks they should control how I store a phone number. I may write it something like:

1-800-VERIZON
or
1-800-8374966

why would I want to be forced to:
18008374966

My current work phone number is:

+90 (232) 278 55 65 (Ext:156)

As a human I can memorize this number at a glance and would hate it to be:

902322785565156

or anything in between parsing this whole thing into multiple unnecessary boxes. It is not so hard to write regular expression for these if you feel you need to validate anyway.

My 0.2 cents.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform