delete表连接不支持limit
mysql> delete test1 from test1 join test2 on test1.id=test2.id limit 10;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'limit 10' at line 1
mysql>
------解决方案--------------------
delete A FROM test1 A INNER JOIN (SELECT ID FROM test2 limit 10) B
on A.id=B.id ;