Link to home
Start Free TrialLog in
Avatar of Breadstick
Breadstick

asked on

Very simple mysql query question

Here's what I got:

$result = mysql_query("SELECT * from articles where dateadded >= now() - interval 7 day");

That gives me the articles that were added within the last week.  I want the result to be sorted in reverse order by when they were added, so the most recent articles appear first.
ASKER CERTIFIED SOLUTION
Avatar of lozloz
lozloz

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Breadstick
Breadstick

ASKER

Thanks.
Simply add trhe following code @ the end of your SQL statement << ORDER BY dateadded DESC>>(DESC = decending)
yes, that is what i said
<?
function echo_echo() {
  echo "echo";
  echo_echo();
}
?>

:p