SELECT * FROM `support_start` WHERE (NOW() - (60*7)) > TO_DAYS(date)

Not the most optimized way of doing it, but it would work.  60 seconds in a
minute and 7 minutes is the example.

Donny

> -----Original Message-----
> From: Scott Haneda [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, January 28, 2004 12:01 AM
> To: MySql
> Subject: Select older than minutes
> 
> 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.
> 
> Thanks
> 
> 
> --
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:
> http://lists.mysql.com/[EMAIL PROTECTED]




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

Reply via email to