Pada Wed, 28 Aug 2002 17:33:57 -0500
"Naushit Sakarvadia" <[EMAIL PROTECTED]> menulis :

> Is it possible to limit size of table?
> 
> For example I want  xyz table to limit 1 GB and once it reaches
> 1 GB it should start overwriting  oldest data.
> 
> Is it possible to do this in Mysql? or is there any client that can
> monitor table and truncate it?
> 
> I am basically logging some high volume log to mysql and I am not interested
> in very old data but  i want to limit the diskspace.

Why don't you create a script to dispose old data ?

for example :

from shell script or php ... and if you have timestamp field, and $limit = 30 days ago
        delete from table where date < "$limit"; 

and put the script into crontab or other scheduler application ;-)

-- 
Linux: Where Don't We Want To Go Today?
        -- Submitted by Pancrazio De Mauro, paraphrasing some well-known sales talk
 
MySQL 3.23.51 : up 68 days, Queries : 358.692 per second (avg).

--
Dicky Wahyu Purnomo - System Administrator
PT FIRSTWAP : Jl Kapt. Tendean No. 34 - Jakarta Selatan 12790
Phone : +62 21 79199577 - HP : +62 8551044244 - Web : http://www.1rstwap.com


---------------------------------------------------------------------
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