Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Order By Date

Status
Not open for further replies.
Aug 23, 2004
174
US
I am trying to set up a page for a band that will display the next show first followed by the next date and so on. Here is my sql that isn't working properly.

$shows = mysql_query("SELECT date_format(date, '%a, %b %D, %Y') as date, venue, location, state, bands, start_time, cover, age
FROM shows
WHERE date >= sysdate()
ORDER BY date DESC");

Any ideas how to make this work?

Thanks.
 
when you are formatting your date for output, give it a different alias name and then still order by date.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top