Justtechjobs.com Find a programming school near you






Online Campus Both


php-general | 2001072

[PHP] Re: Sort by bigger count(*) From: Andrew Sterling Hanenkamp (sterling <email protected>)
Date: 07/31/01

Unless you've used GROUP BY you'll only return one row. I think that
something like

SELECT x, count(y)
FROM table
GROUP BY y
ORDER BY count(y);

Ought to work.

Later,
Sterling

Elias wrote:

> Hello,
>
> I made a query that uses count(*)
> now how can i get the results sorted following the biggest count(*) result?
>
>
>
>

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-general-unsubscribe <email protected>
For additional commands, e-mail: php-general-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>