top of page
CerebroSQL

ENUM

База данных: MySQL

68747470733a2f2f7374796c65732e7265646469746d656469612e636f6d2f74355f32716d366b2f7374796c65

ENUM('value1','value2',...) [CHARACTER SET charset_name] [COLLATE
collation_name]

An enumeration. A string object that can have only one value, chosen
from the list of values 'value1', 'value2', ..., NULL or the special ''
error value. ENUM values are represented internally as integers.

An ENUM column can have a maximum of 65,535 distinct elements.

The maximum supported length of an individual ENUM element is M <= 255
and (M x w) <= 1020, where M is the element literal length and w is the
number of bytes required for the maximum-length character in the
character set.

Example

bottom of page