Yes!  My apologies; didn't have my coffee this morning.  The column is of
type SET.

Jeff

> -----Original Message-----
> From: Paul DuBois [mailto:[EMAIL PROTECTED]]
> Sent: Wednesday, June 12, 2002 12:50 PM
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: Re: ENUM query question
>
>
> At 12:42 -0500 6/12/02, Jeff Field wrote:
> >I have a quick question regarding queries that involve values in ENUM
> >columns.  Here's the scenario:
> >
> >I have an ENUM column (category) that can have the values ('Gambling',
> >'Geographic', 'Medical', 'Sports').  Most of the records have only one of
> >the category descriptions but some are categorized in two or more of the
> >category descriptions.
>
> That's impossible.  It sounds like you really mean SET, not ENUM.
>
> >When I do a query and my WHERE clause is
> >
> >WHERE category = 'Gambling'
> >
> >it only pulls the records for which 'Gambling' is the only value.  To get
> >*all* the records, including the records where the category
> value might be
> >(Gambling, Sports), I have to use the wildcard, as in
> >
> >WHERE category = '%Gambling%'
> >
> >Here's the question:
> >
> >Although this may be exactly what I have to do to get those
> records, my own
> >personal expectation was that the first query (without the
> wildcards) should
> >have been fine.  Is having to use wildcards with an ENUM column
> in the WHERE
> >clause correct?  Or, am I missing something here?
> >
> >Thanks!
> >
> >Jeff
>
>
> ---------------------------------------------------------------------
> Before posting, please check:
>    http://www.mysql.com/manual.php   (the manual)
>    http://lists.mysql.com/           (the list archive)
>
> To request this thread, e-mail <[EMAIL PROTECTED]>
> To unsubscribe, e-mail <[EMAIL PROTECTED]>
> Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php
>
>


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to