On Wednesday 28 January 2004 06:00, Scott Haneda wrote:
> I have done this so many times..
> SELECT * FROM `support_start` WHERE TO_DAYS(NOW()) - TO_DAYS(date) > 7
>
> I have scoured (more like glanced :-)) at the docs on
> <http://www.mysql.com/doc/en/Date_and_time_functions.html> and can not seem
> to find how to get all records where a timestamp(14) is older than x
> minutes.

You haven't said which version of MySQL you're using.

That said:
DATE_SUB.

select * from support_start where time_stamp_field > date_sub(now, interval x 
minute);

Sub for time_stamp_field and x as needed.

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to