Jump to content

[SOLVED] returning all records made within the last 24hrs


debuitls

Recommended Posts

Hi,

 

I'm trying to return all records from a mysql table that have a timestamp of within the last 24hrs.

 

$result = mysql_query("SELECT * FROM table WHERE where time >= NOW()- INTERVAL 1 DAY");

 

Just wondering if anybody can see off the top of their head why the above isnt working?

 

any suggestion would be much appreciated

 

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.