Most Read Article
| From: | Jordan Elver | Date: | Mon, 05 Nov 2001 09:36:44 +0000 |
| Subject: | Most Read Article | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-14006@lists.php.net to get a copy of this message | ||
Hi,
I'm trying to get the most read article out a table.
The table has a title column, a read column and some others.
So I wanna SELECT the title from the table and the most read figure.
I tried:
SELECT title, MAX(reads) FROM articles
This only gets the second most read article?! If I take out the title like:
SELECT MAX(reads) FROM articles
Then it gets the top article number but obviously not the title.
Can anyone shed some light?
Cheers,
Jord
--
Jordan Elver
Web Developer
The InternetOne UK Ltd