delete from table where...
当取别名时,有可能会报: 别名附近有错误( 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 't...)
delete from table t where t.id=...
因为有别名时,等同于两个表.要指定一个表名
更正为:
delete t from table t where t.id=...
delete 后加上别名 就成功了。。。