I'm designing a system that will parse and store log files in a
MySQL-Max-2.23 database (the log table will be innodb).  I have a
requirement that as the database fills towards maximum capacity that it
writes over the oldest records rather than dropping new records.  

I'd like to know if this is something that can be handled by the
database itself?  Otherwise it will be up to the application.  Has
anyone written code to do this?  Is it best to delete a chunk of old
records when its full then continue inserting, or would something like:

 UPDATE logs SET col=data, date=newdate ORDER BY date DESC LIMIT 1

be better once the table was at capacity? (would this work at all?)



Thanks, 
Eric Mayers

Software Engineer
Captus Networks

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to