Jump to: navigation, search

Mysql Strings Data Types

From w3cyberlearnings
# Type Storage Range Description Attribute Default Value
1 CHAR A fixed section from 0 to 255 characters long The length of a CHAR column is fixed to the length that you declare when you create the table. BINARY, CHARACTER SET NULL,""
2 VARCHAR A variable section from 0 to 255 characters long. For VARCHAR columns, trailing spaces in excess of the column length are truncated prior to insertion and a warning is generated, regardless of the SQL mode in use BINARY, CHARACTER SET NULL,""
3 BINARY A fixed section from 0 to 255 characters long IS similar to Char except that they are contain binary strings rather than nonbinary strings. BINARY, CHARACTER SET NULL, ""
4 VARBINARY A variable section from 0 to 255 characters long. Is a binary version of VARCHAR BINARY, CHARACTER SET NULL,""
5 BLOB A string with a maximum length of 65535 characters A BLOB is a binary large object that can hold a variable amount of data. Global Only (Case Sensitive) NULL,""
6 TINYBLOB A string with a maximum length of 0 to 255 characters A binary data/object Global Only (Case Sensitive) NULL, ""
7 MEDIUMBLOB A string with a maximum length of 16777215 characters A binary data/object Global Only (Case Sensitive) NULL, ""
8 LONGBLOB A string with a maximum length of 4294967295 characters A binary data/object Global Only (Case Sensitive) NULL, ""
9 TEXT A string with a maximum length of 65535 characters TEXT values are treated as nonbinary strings BINARY, CHARACTER SET NULL, ""
10 TINYTEXT A string with a maximum length of 255 characters. TEXT values are treated as nonbinary strings BINARY, CHARACTER SET NULL, ""
11 MEDIUMTEXT A string with a maximum length of 16777215 characters. TEXT values are treated as nonbinary strings BINARY, CHARACTER SET NULL, ""
12 LONGTEXT A string with a maximum length of 4294967295 characters. TEXT values are treated as nonbinary strings BINARY, CHARACTER SET NULL, ""


Related Links

Navigation
Web
SQL
MISC
References