when retrieving data from the db and displaying it on the
page by creation date how can i reverse the order so that the most
recent entry appears first? here's what i have now:
?
require(config.php);
$obj = mysql_db_query($dbname,select * from ads order by
createdate);
?
You
Simple MySQL.
After your ORDER BY clause use either ASC (I think this is the default) or
DESC. I'm pretty sure this'll work on date fields to produce the results you
want.
Your query will end up looking like:
...order by createdate DESC
-Original Message-
From: Addison Ellis
thank you... this worked. best, addison
Simple MySQL.
After your ORDER BY clause use either ASC (I think this is the default) or
DESC. I'm pretty sure this'll work on date fields to produce the results you
want.
Your query will end up looking like:
...order by createdate DESC
-Original