Is there a standard for storing normalized phone numbers in a database?

前端 未结 18 1511
佛祖请我去吃肉
佛祖请我去吃肉 2020-11-28 19:23

What is a good data structure for storing phone numbers in database fields? I\'m looking for something that is flexible enough to handle international numbers, and also som

18条回答
  •  情书的邮戳
    2020-11-28 19:41

    I personally like the idea of storing a normalized varchar phone number (e.g. 9991234567) then, of course, formatting that phone number inline as you display it.

    This way all the data in your database is "clean" and free of formatting

提交回复
热议问题