On Fri, Apr 20, 2001 at 03:09:32PM -0600, Jeff Shipman - SysProg wrote:
> }
> } You don't need to create another column, just use:
> }
> } ORDER BY category = 'other', category
> }
> 
> Are you sure this works? My query is:
> 
> select category,subcategory from categories ORDER BY
> category = 'other', category;
> 
> And I get:
> 
> ERROR 1064: You have an error in your SQL syntax
> near '= 'other', category' at line 1

Yes. And I of course tested before I posted. I also tried 

ORDER BY category in ('cat1','cat2'), category

which worked.

I'm running 3.23.36 on debian linux.

Well, actually, rather than create a new table, I used an existing one.
The actual statement was

select last_name from mizpah where first_name like 'fr%' order by
last_name = 'crosby', last_name;

-- 
"Moderation in temper is always a virtue; but moderation in
 principle is always a vice."
                -- Thomas Paine, _The Rights of Man_ (1791)
                   Rick Pasotto email: [EMAIL PROTECTED]

---------------------------------------------------------------------
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