MySQL Binary Data Types
In this tutorial, we will learn about MySQL Binary Data Types. Binary data types are thought of as a sequence of bytes rather than a sequence of characters. Binary data types are suitable for storing images, sound, and PDF documents.
An important thing to realize is that the textual representation of a binary string usually has nothing to do with the ‘real’ meaning of the binary string. This is an important difference with respect to character strings, which textual representation usually corresponds exactly with their meaning. Consequently, binary strings do not have an associated character set or collation.
Binary String Data Types
The following are the binary string data types supported by MySQL:
BINARY — This data type is similar to the CHAR type, but stores binary strings rather than non-binary character strings.
VARBINARY–This data type is similar to the VARCHAR (variable-length) type, but stores binary byte strings rather than non-binary character strings.
TINYBLOB-– This data type is a BLOB column with a maximum length of 255 bytes.
A blob is a collection of binary data stored as a single entity in a database management system. Blobs are typically images, audio or other multimedia objects, though sometimes binary code is stored as a blob.
BLOB-– This data type is a BLOB column with a maximum length of 65,535 bytes.
MEDIUMBLOB--This data type is a BLOB column with a maximum length of 16,777,215 bytes.
LONGBLOB— This data type is a BLOB column with a maximum length of 4,294,967,295 bytes.
—
MySQL Tutorials
MySQL Tutorials on this website:
https://www.testingdocs.com/mysql-tutorials-for-beginners/
For more information on MySQL Database: