[EMAIL PROTECTED] writes:
> Your message cannot be posted because it appears to be either spam or
> simply off topic to our filter. To bypass the filter you must include
> one of the following words in your message:
>
> database,sql,query
This is _very_ annoying.
Paul DuBois writes:
> At 6:03 PM -0300 5/24/01, Adriano Nagelschmidt Rodrigues wrote:
> >
> >level ENUM('bad', 'good', 'great') NOT NULL
[snip]
> >SELECT * FROM foo WHERE level >= 'good'
[snip]
> >Shouldn't a numeric context be applied by the server in this case? eg,
>
> Why? 'good' isn't a number, and it's perfectly legal to compare strings
> with the >= operator.
Because you can (actually, you do) define whatever order you want in
the ENUM declaration (even alphanum order).
The way it works now, I have to know in which position the label
'good' is to construct the select. I think this leads to unnecessary
duplication (is there a function that returns the position of a label?
I couldn't find it in the manual).
IMHO, if it were abstracted away by the server we would have better
functionality.
Regards,
--
Adriano
---------------------------------------------------------------------
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
bad filter, and Re: SELECT and (ordered) ENUMs
Adriano Nagelschmidt Rodrigues Thu, 24 May 2001 14:59:21 -0700
