What's the matter with MySQL (1) How to store mobile phone number and landline number

Source: Internet
Author: User

When you create a MySQL data table, you often encounter storage problems with your mobile phone number and landline number data.

First say mobile phone number: Many people like to use numbers to store, mobile phone number does not involve operations, and sometimes with parentheses, plus and other characters, and sometimes start with 0. Therefore, the mobile phone number is best to use varchar (20) to store, so that the storage can support fuzzy query.

There are two ways to store landline numbers, one is to store the landline code and the landline number separately as varchar. One is to use a varchar to store the entire landline phone number.

What's the matter with MySQL (1) How to store mobile phone number and landline number

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.