RE: [PHP-DB] datetime

From: Date: Wed, 22 Jan 2003 10:10:02 +0000
Subject: RE: [PHP-DB] datetime
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-25035@lists.php.net to get a copy of this message
> hello and thank you... probably again. > using datetime, &/or something else if applicable, is it possible to > have entries to a page and entries to a db automatically delete? i > have looked through many docs at php.net and mysql and can't find > anything. perhaps i'm using the wrong search key words.? thanks > again, Addison Well, no, not automatically. But you can run a query to delete records that are over X days old. DELETE FROM table WHERE datetime_field < CURDATE() - INTERVAL 30 DAYS Will delete anything over 30 days old. Adapt to your needs. ---John W. Holmes... PHP Architect - A monthly magazine for PHP Professionals. Get your copy today. http://www.phparch.com/

« previous php.db (#25035) next »