View Single Post

   
  #2 (permalink)  
Old 02-28-2008, 07:37 AM
Ricardas S
 
Posts: n/a
Default Re: How can I do something like this "SELECT MAX(col1, col2, col3) FROM mytable ORDER BY MAX(col1, col2, col3);" ?

Have you tried
MAX((col1*(MAX_VALUE_OF_COL1+1)+col2)*(MAX_VALUE_O F_COL2+1)+col3)

----- Original Message -----
From: "KLEIN Stéphane" <klein.stephane@gmail.com>
To: <mysql@lists.mysql.com>
Sent: Wednesday, June 13, 2007 09:30
Subject: How can I do something like this "SELECT MAX(col1, col2, col3) FROM mytable ORDER BY MAX(col1, col2, col3);" ?


> Hi,
>
> I would like do something like :
>
> SELECT MAX(col1, col2, col3) FROM mytable ORDER BY MAX(col1, col2, col3);
>
> I know this syntax is wrong but I would like get a solution to this stuff.
>
> Thanks for your help.
> Stephane
>
> --
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe: http://lists.mysql.com/mysql?unsub=rs@nfq.lt
>


Reply With Quote