Jump to Navigation

051 - BLOB

This column data type allows for the storage of a large amount of binary data. You may give a width with this data type; the maximum is 65,535 bytes. If you attempt to store a value in a BLOB column that is larger thanits limit, unless the server is set to SQL strict mode, the data will be truncated and warning message will be generated. If strict mode is on, the data will be rejected and an error will be returned. A BLOB column cannot have a default value. For sorting data, the value given for the system variable max_sort_length will be used.Only the number of bytes specified by that variable for each column will be included in sorts.

  • BLOB[(width)]
  • TINYBLOB (255 bytes)
  • MEDIUMBLOB (16,777,215 bytes)
  • LONG BLOB (4GB)

 

MySQL:


Main menu 2

Story | by Dr. Radut