About 240,000 results
Open links in new tab
  1. Create enum in SQL Server - Stack Overflow

    Sep 7, 2018 · 19 There is no enum datatype available in SQL Server like in MySQL. But using the CHECK constraint enum functionality can be implemented.

  2. What would you use ENUM for in SQL?

    Mar 11, 2019 · To add, the classic enum use case is gender (M/F, albeit you might want to include an O for Other nowadays) or other attributes that have to fit into a specific list and can only …

  3. sql - When to use an enum or a small table in a relational database ...

    Jul 10, 2014 · That's a good point, but then, when to use an enum over a small table? My concern started when I was modelling the database and saw all those small tables everywhere, and …

  4. SQL query to get all values a enum can have - Stack Overflow

    Feb 26, 2017 · Postgresql got enum support some time ago. CREATE TYPE myenum AS ENUM ( 'value1', 'value2', ); How do I get all values specified in the enum with a query?

  5. sql server - Simulate enums in TSQL? - Stack Overflow

    May 16, 2012 · CREATE PROCEDURE Proc_search_with_enum @user int, @account_category {enum} I understand that SQL 2000 doesn't have enums as a first class language construct, …

  6. SQL Server equivalent to MySQL enum data type? - Stack Overflow

    Sep 16, 2009 · Does SQL Server 2008 have a a data-type like MySQL's enum?

  7. Does an enum in MySQL need to be NOT NULL? - Stack Overflow

    Jun 11, 2015 · 4 In ENUM data type, if you do not declare NOT NULL then it gives the default value NULL. However, if you declare NOT NULL then it gives the first value from the ENUM.

  8. How to display the string Enum values instead of the number …

    Sep 25, 2015 · I think this is because I have used Enum to store my status values? I wish to display the word Dispatched instead of the number value that it represents in the Enum. I'm …

  9. SQL: Advantages of an ENUM vs. a one-to-many relationship?

    Dec 21, 2010 · In a Normal Standard SQL database, you simply Insert/Update/Delete a row in the Lookup table. Last, you cannot easily get a list of the content of the ENUM; you can with a …

  10. database - MySQL enum vs. set - Stack Overflow

    MySQL stores ENUM string values internally as decimal integers of values 1 through n for a column with n members in the enumeration. MySQL represents SET string values as a bitmap …