[Resolved] MySQL: DELETE FROM problems
SQL Statement: DELETE FROM vbsNews_news ORDER BY postedOn LIMIT 1
Error: You have an error in your SQL syntax near 'ORDER BY postedOn LIMIT 1' at line 1
I double-checked the tablename and fieldname and they are both correct (capitalization and all). So what am I doing wrong?
I also tried throwing in a DESC/ASC and WHERE statement to see if it needed those, but no luck.
What I'm trying to do is delete ALL the records in a table EXCEPT for the last X amount (most recent X added).
So where did I screw up?