The following column types are supported:
| Name | Description | Size |
| TINYINT[(M)] [UNSIGNED] [ZEROFILL] | A very small integer. Signed range -128 - 127. Unsigned range 0 - 255. | 1 |
| SMALLINT[(M)]. [UNSIGNED] [ZEROFILL] | A small integer. Signed range -32768 - 32767. Unsigned range 0 - 65535. | 2 |
| MEDIUMINT[(M)] [UNSIGNED] [ZEROFILL] | A medium integer. Signed range -8388608-8388607. Unsigned range 0 - 16777215. | 3 |
| INT[(M)] [UNSIGNED] [ZEROFILL] | A normal integer. Signed range -2147483648 - 2147483647. Unsigned range 0 - 4294967295. | 4 |
| BIGINT[(M)] [UNSIGNED] [ZEROFILL] | A large integer. Signed range -9223372036854775808 - 9223372036854775807. Unsigned Range 0 - 18446744073709551615. Because all arithmetic is done with signed BIGINT or DOUBLE, one shouldn't use unsigned big integers bigger than 9223372036854775807 (63 bits) with anything else than bit functions! | 8 |
| FLOAT(Precision) | A small floating point number. Precision can be 4 or 8. FLOAT(4) is a single precision number and FLOAT(8) is a double precision number (se the DOUBLE entry). This syntax is for ODBC compatibility. Range -3.402823466E+38F - -1.175494351E-38, 0, -1.175494351E-38 - 3.402823466E+38F. | 4 |
| FLOAT[(M,D)] | A small floating point number. Cannot be unsigned. Range -3.402823466E+38F - -1.175494351E-38, 0, -1.175494351E-38 - 3.402823466E+38F. | 4 |
| DOUBLE PRECISION[(M,D)] | A normal floating point number. Cannot be unsigned. Range -1.7976931348623157E+308 - -2.2250738585072014E-308, 0, 2.2250738585072014E-308 - 1.7976931348623157E+308. | 8 |
| REAL[(M,D)] | Same as DOUBLE | 8 |
| DECIMAL [(M,D)] | An unpacked floating point number. Cannot be unsigned. Currently the same range maximum range as a double. Behaves as a CHAR column | M+D |
| NUMERIC [(M,D)] | Same as DECIMAL | M+D |
| TIMESTAMP [(M)] | An automatic timestamp. If you have many TIMESTAMP columns only the first one is automatic | 4 |
| DATE | A type to store date information. Uses the "YYYY-MM-DD" syntax, but may be updated with a number or a string. Understands at least the following syntaxes: 'YY-MM-DD', 'YYYY-MM-DD', 'YYMMDD' and full timestamps (YYYYMMDDHHMMDD). Range 0000-00-00 to 9999-12-31. | 3 |
| TIME | A type to store time information. Uses the "HH:MM:SS" syntax, but may be updated with a number or a string. Understands at least the following syntaxes: 'HH:MM:SS, 'HHMMSS', 'HHMM', 'HH'. | 3 |
| DATETIME | A type to store date and time information. Format "YYYY-MM-DD HH:MM:SS". Takes 8 bytes. Range '0000-01-01 00:00:00' - '9999-12-31 23:59:59'. | 8 |
| YEAR | A type to store years. Format "YYYY" or "YY". Takes 1 byte. Range 0, 1901-2155. 2 digits years in the range 00-69 is assumed to be 2000-2069 and will be sorted correctly. (now type for MySQL 3.22) | 1 |
| CHAR(M) [binary] | A fixed length string that is always filled up with spaces to the specified length. Range 1 - 255 characters. All end space are removed when retrieved. Is sorted and compared case insensitively unless the binary keyword is given. | M |
| VARCHAR(M) [binary] | A variable length string that is stored with its length. All end space are removed when storing it. Maximum range 1 - 255 characters. Is sorted and compared case insensitively unless the binary keyword is given. | L+1 |
| TINYTEXT and TINYBLOB |
A TEXT/BLOB with max length of 255 characters. | L+1 |
| TEXT and BLOB |
A TEXT/BLOB with max length of 65535 characters. | L+2 |
| MEDIUMTEXT and MEDIUMBLOB |
A TEXT/BLOB with max length of 16777216 characters. | L+3 |
| LONGTEXT and LONGBLOB |
A TEXT/BLOB with max length of 4294967295 characters. | L+4 |
| ENUM('value','value2',...) | A string object that can have only one set of allowed values (or NULL). See section More about data types | 1 or 2 |
| SET('value','value2',...) | A string object that can have one or many values of a set of allowed values. See section More about data types. | 1-8 |
Go to the first, previous, next, last section, table of contents.