MySQL selection criteria for data types (important)

Source: Internet
Author: User

1. allowable values : the range and type of values allowed in a field is the most immediate factor in determining which data type to add to this field.

2. storage Efficiency : It is also important to consider the range of possible values for a field and to choose a suitable, well-sized data type based on that range, especially when dealing with numeric types.

3. format and display requirements : Another important factor that affects field type selection is the application format and display requirements for the data stored in the field.

4. Data Processing requirements : The choice of the type should also take into account data manipulation and application processing requirements, such as some types are more appropriate to speed up data operations rather than other aspects.

5. sorting, indexing and comparison requirements : If you want different criteria to sort all the values in a column, then we need to choose a type that performs these functions efficiently and with maximum flexibility. Adding an index to the corresponding field can speed up the retrieval. The type of comparison should also be used for data types that need to ensure that the data types used support comparison operations and are compatible with each other.

MySQL selection criteria for data types (important)

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.