I have table "n" with columns: auto_id, title, date, category.
If I 'Select count(*), category from n group by category',
I see the count of items by category, as I intended.
My logic problem is that when the count(*) is >100 I want to delete the oldest rows (as determined by column 'time') until there are <=100 rows. How can I do this??? (essentially retiring old information to the bit bucket).
THANKS!
If I 'Select count(*), category from n group by category',
I see the count of items by category, as I intended.
My logic problem is that when the count(*) is >100 I want to delete the oldest rows (as determined by column 'time') until there are <=100 rows. How can I do this??? (essentially retiring old information to the bit bucket).
THANKS!