Re: Ordering output

From: Date: Thu, 25 Apr 2002 21:03:45 +0000
Subject: Re: Ordering output
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-94661@lists.php.net to get a copy of this message
On Thu, 25 Apr 2002, Steve Buehler wrote: > I am using PHP to access a mysql database. I was told that what I need to > do needs to be done in PHP and not mysql. I can get mysql to order things > like this: > Select * from $temp2 where sea_id = '$sea_id' order by pts DESC > The problem is that if there is a tie (as in ranking 4 and 5 below), I need > to run another query to check to see if something else has happened and if > it happened, than that team would be a higher rank than the other. It is > possible to have more than 2 teams tieing too. So I have to be able to > determine what order the teams should be in. Well, we don't know what the secondary sorting criterion is, but my guess is that you could have your database take care of that too in the same query. miguel

« previous php.general (#94661) next »