Delete rows older than 14 days in MySQL
问题 Summary I need to purge the history of a table from rows that are older than 14 days. Being no MySQL Expert, my searches lead me to this: delete from SYS_VERROUS_POLICE where idModificationPolice not in ( select distinct idModificationPolice from SYS_VERROUS_POLICE where date(dateHeureModification) between curdate() and curdate() - interval 14 day ); Thrown Exception But then I'm stuck with this error message: Error Code: 1093. You can't specify target table 'SYS_VERROUS_POLICE' for update in