ENUM
This page is part of MariaDB's Documentation.
The parent of this page is: Data Types for MariaDB Enterprise Server
Topics on this page:
Overview
A single value from up to 65,535 pre-selected options.
EXAMPLES
Example of ENUM
:
CREATE TABLE enum_example (
description VARCHAR(20),
example ENUM('Alpha', 'Beta', 'Gamma', 'RC', 'Stable')
);
INSERT INTO enum_example VALUES
('foo', 'Beta'),
('bar', 'RC'),
('baz', 'Alpha'),
('bob', 5);
SELECT * FROM enum_example;
+-------------+---------+
| description | example |
+-------------+---------+
| foo | Beta |
| bar | RC |
| baz | Alpha |
| bob | Stable |
+-------------+---------+
CHANGE HISTORY
EXTERNAL REFERENCES
Additional information on this topic may be found in the MariaDB Public Knowledge Base.