RE: [PHP] Last visitors

From: Date: Tue, 19 Apr 2005 13:43:07 +0000
Subject: RE: [PHP] Last visitors
Groups: php.general 
Request: Send a blank email to php-general+get-213356@lists.php.net to get a copy of this message
Hey, > As to exactly how you decide which are the most recent 10 records to do > > this deletion, that is a little more complex. Yep, for sure > Something like > > DELETE FROM profile_visits > > WHERE user='billy' > > AND time_of_visit NOT IN ( > > Select time_of_visit > > FROM > > profile_visits > > WHERE user='billy' > > ORDER by time_of_visit DESC LIMIT 10 > > ) > > > > Should give you an idea. Yep, gets me thinking in a few other directions... I am also toying with the idea of having a txt file for each profile (instead of using the DB) and fetch/record/delete/update the last 10 there... what do you think? easier? Thanks, Ryan -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.0.308 / Virus Database: 266.9.16 - Release Date: 4/18/2005

« previous php.general (#213356) next »