RE: [PHP] Getting the highest number in a column

From: Date: Tue, 15 Oct 2002 07:34:36 +0000
Subject: RE: [PHP] Getting the highest number in a column
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-119990@lists.php.net to get a copy of this message
> Using PHP and a MySQL database, I want to grab the highest > number in a particular column. As is usual for questions like this, the answer is most likely that you should do it in your sql query. In this case, something like this would probably do it: SELECT MAX(some_column) FROM some_table WHERE some = condition CYA, Dave

« previous php.general (#119990) next »