salman_ahad@yahoo.com Posted November 9, 2009 Share Posted November 9, 2009 .. $query = mysql_query("DELETE FROM *table* WHERE datetime > 3 days back")or die(mysql_error()); My error? Quote Link to comment Share on other sites More sharing options...
salman_ahad@yahoo.com Posted November 9, 2009 Author Share Posted November 9, 2009 Any HELP $query_users = mysql_query("DELETE FROM *table* WHERE date_time < SYSDATE - 3 ")or die(mysql_error()); //I am trying to delete all data 3 days old Quote Link to comment Share on other sites More sharing options...
Maq Posted November 9, 2009 Share Posted November 9, 2009 What's the error? 1) Not sure what *table* is. 2) Which query are you using? Quote Link to comment Share on other sites More sharing options...
salman_ahad@yahoo.com Posted November 9, 2009 Author Share Posted November 9, 2009 Fixed it!! thanks though Maq $query_users = mysql_query("DELETE FROM test1 WHERE date_time < (curdate() - 2)")or die(mysql_error()); Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.