About 4,290,000 results
Open links in new tab
  1. ENUM in MySQL - GeeksforGeeks

    Jun 15, 2024 · The ENUM data type in MySQL is a string object that allows us to limit the value chosen from a list of permitted values in the column specification at the time of column creation. ENUM values are stored as integers (1, 2, 3, …) behind the scenes, which is more space-efficient than storing strings.

  2. MySQL :: MySQL 8.0 Reference Manual :: 11.3.5 The ENUM Type

    An ENUM is a string object with a value chosen from a list of permitted values that are enumerated explicitly in the column specification at table creation time. See Section 11.3.1, “String Data Type Syntax” for ENUM type syntax and …

  3. Create enum in SQL Server - Stack Overflow

    Sep 7, 2018 · In MySQL one can create an enum as such: USE WorldofWarcraft; CREATE TABLE [users] ( ID INT NOT NULL IDENTITY(1,1) PRIMARY KEY, username varchar(255), password varchar(255), mail varchar (255), rank ENUM ('Fresh meat', 'Intern','Janitor','Lieutenant','Supreme being')DEFAULT 'Fresh meat', );

  4. Using ENUM in MySQL 8: A Practical Guide (with Examples)

    Feb 1, 2024 · Its main purpose is to limit the possible values that can be inserted into a column to a fixed list specified during table creation. Here is an example: size ENUM('small', 'medium', 'large') NOT NULL . Now, only ‘small’, ‘medium’, or ‘large’ can be inserted into the ‘size’ column.

  5. MySQL ENUM Data Type - MySQL Tutorial

    This tutorial introduces you to MySQL ENUM data type and shows you how to define ENUM columns for storing enumeration values.

  6. MySQL - ENUM: A Friendly Guide for Beginners - MySQL Data Types

    ENUM, short for "enumeration," is a fancy way of saying "a list of predefined options." It's like a multiple-choice question where MySQL only allows answers from the choices you've given. Let's create a simple table to demonstrate: id INT AUTO_INCREMENT PRIMARY KEY, customer_name VARCHAR (50), size ENUM('small', 'medium', 'large')

  7. SQL SERVER – Enumerations in Relational Database – Best Practice

    Mar 22, 2010 · Value tells the enumeration value which is used in Person table (I’ll show how this is done below). Description tells what the value means. You can use this, for example, column in UI’s combo box.

  8. How to use enum : ENUM « Data Type « SQL / MySQL - Java2s

    Consider changing the column type to ENUM, if you always sort a non-enumeration column in a specific non-lexic 12. Use ALTER TABLE to convert the name column to an ENUM that lists the colors in the desired sort order:

  9. sql server - Storing enum values in database - Stack Overflow

    May 25, 2011 · All of the sudden you need to get a DBA involved (depending on where/how you work) just to change an enumeration value, or suffer with it. Parsing an enum has some performance impact as well since things like Locale come into play, but probably negligible. What problem does that solve?

  10. MySQL :: MySQL 8.4 Reference Manual :: 13.3.5 The ENUM Type

    To determine all possible values for an ENUM column, use SHOW COLUMNS FROM tbl_name LIKE 'enum_col' and parse the ENUM definition in the Type column of the output. In the C API, ENUM values are returned as strings.

  11. Some results have been removed