Ordering by dates

From: Date: Sat, 11 Nov 2000 05:18:08 +0000
Subject: Ordering by dates
Groups: php.general 
Request: Send a blank email to php-general+get-24761@lists.php.net to get a copy of this message
Hey list, How would I order the following by date. The dates are in mm-dd format (Eg: 11-10). This is a problem when trying to order the events by their date. Here's a snippet of mysql table: sport location date time opponent -------------------------------- Football Maxwell 9-20 7:30 Colo-Nesco Football Baxter 10-13 7:30 North Polk Football Collins 10-1 7:30 West Marshall Now, is there anyway I could order these by date. A simple mysql_query("SELECT * FROM sports WHERE sport = '$sport' ORDER BY date ASC"); doesn't exactly work. I suppose it's because of the date format. Would this be easier to convert the dates to timestamps? Any ideas would be very very much appreciated. Thanks! Tyler Longren Just for some background info, this is a project for school. It's a listing of sporting events for my school.

« previous php.general (#24761) next »