Table of Contents [+/-]
- 11.1 Data Type Overview [+/-]
- 11.2 Numeric Types [+/-]
- 11.3 Date and Time Types [+/-]
- 11.4 String Types [+/-]
- 11.5 Extensions for Spatial Data [+/-]
- 11.6 Data Type Default Values
- 11.7 Data Type Storage Requirements
- 11.8 Choosing the Right Type for a Column
- 11.9 Using Data Types from Other Database Engines
MySQL supports a number of data types in several categories: numeric types, date and time types, string (character and byte) types, and spatial types. This chapter provides an overview of these data types, a more detailed description of the properties of the types in each category, and a summary of the data type storage requirements. The initial overview is intentionally brief. The more detailed descriptions later in the chapter should be consulted for additional information about particular data types, such as the permissible formats in which you can specify values.
Data type descriptions use these conventions:
Mindicates the maximum display width for integer types. For floating-point and fixed-point types,
Mis the total number of digits that can be stored (the precision). For string types,
Mis the maximum length. The maximum permissible value of
Mdepends on the data type.