List:General Discussion« Previous MessageNext Message »
From:Jerry Schwartz Date:July 31 2008 4:21pm
Subject:RE: SET vs. ENUM
View as plain text  
>From: pharkins@stripped [mailto:pharkins@stripped] On Behalf Of Perrin
>Harkins
>Sent: Thursday, July 31, 2008 11:25 AM
>To: Jerry Schwartz
>Cc: mysql@stripped
>Subject: Re: SET vs. ENUM
>
>On Thu, Jul 31, 2008 at 9:46 AM, Jerry Schwartz
><jschwartz@stripped> wrote:
>> Other than the fact that an ENUM can have many more values than a SET,
>is
>> there any particular reason to choose one over the other?
>
>The only use for ENUM is to make your data smaller.  It offers no
>protection against illegal values and can't be updated without copying
>the table.  If you want to constrain values, a better approach is to
>make your tables InnoDB and use a lookup table with a foreign key
>constraint.
>
[JS] Too late, I inherited this. There are a LOT of places where foreign key
restraints (and cascading deletes) would save a lot of programming.

I do, however, make use of full-text indexing.
>- Perrin



Thread
SET vs. ENUMJerry Schwartz31 Jul
  • Re: SET vs. ENUMMartijn Tonies31 Jul
    • RE: SET vs. ENUMJerry Schwartz31 Jul
  • Re: SET vs. ENUMMartijn Tonies31 Jul
    • RE: SET vs. ENUMJerry Schwartz31 Jul
      • Re: SET vs. ENUMChris W31 Jul
        • Re: SET vs. ENUMMr. Shawn H. Corey31 Jul
          • Re: SET vs. ENUMChris W31 Jul
  • Re: SET vs. ENUMPerrin Harkins31 Jul
    • Re: SET vs. ENUMMr. Shawn H. Corey31 Jul
      • Re: SET vs. ENUMPerrin Harkins31 Jul
    • RE: SET vs. ENUMJerry Schwartz31 Jul
  • Re: SET vs. ENUMMartijn Tonies1 Aug