Often people in newsgroups ask about maximum size of various objects defined in databases.
The following tables shows the maximum sizes and numbers of various objects defined in MYSql, SQL Server.
Char | 255 Bytes |
Varchar | 65,535 Bytes |
Binary | 255 Bytes |
Varbinary | 65,535 Bytes |
TinyBlob | 255 Bytes |
TinyText | 255 Bytes |
Blob | 65,535 Bytes (2^16 -1) |
Text | 65,535 Bytes (2^16 -1) |
Medium Blob | 16,777,215 Bytes (2^24 -1) |
Medium Text | 16,777,215 Bytes (2^24 -1) |
LongBlog | 4,294,967,295 Bytes (2^32 -1) |
LongText | 4,294,967,295 Bytes (2^32 -1) |
Bit | Range from 1 to 64 |
Tinyint | The signed range is -128 to 127. The unsigned range is 0 to 255. |
BOOL, BOOLEAN | true or false |
SmallInt | The signed range is -32768 to 32767. The unsigned range is 0 to 65535. |
MediumInt | The signed range is -8388608 to 8388607. The unsigned range is 0 to 16777215. |
Int/Integer | The signed range is -2147483648 to 2147483647. The unsigned range is 0 to 4294967295. |
BigInt | The signed range is -9223372036854775808 to 9223372036854775807. The unsigned range is 0 to 18446744073709551615. |
Float | Allowable values are -3.402823466E+38 to -1.175494351E-38, 0, and 1.175494351E-38 to 3.402823466E+38. |
Double | Allowable values are -1.7976931348623157E+308 to -2.2250738585072014E-308, 0, and 2.2250738585072014E-308 to 1.7976931348623157E+308. |