Re: [PHP-DB] Really dumb question... deleting everything but newest100 rows?

2002-11-23 Thread Marco Tabini
If you have a column that gives you the newness of each row--I'm assuming a date here: delete from my_table order by date_inserted desc limit 100, -1 This should work... I recommend a db backup first :-) Marco php|architect - The magazine for PHP Professionals The monthly

Re: [PHP-DB] Really dumb question... deleting everything but newest100 rows?

2002-11-23 Thread Leif K-Brooks
I was thinking something along those lines, but phpmyadmin gives an error. The table currently has way too many rows (32362), could this have to do with it? Warning: Unable to jump to row 0 on MySQL result index 4 in /home/virtual/site1/fst/var/www/html/PhpMyAdmin/sql.php on line 223