Date calc with SQL
Micro tip of the day: How many days has past since a date field in the database?
SELECT (TO\_DAYS(NOW()) - TO\_DAYS(date\_field)) AS days\_past FROM tablename
Micro tip of the day: How many days has past since a date field in the database?
SELECT (TO\_DAYS(NOW()) - TO\_DAYS(date\_field)) AS days\_past FROM tablename