Hit9 Blog Wiki Project Links Archives Resumé
Page: First UP Pre Next Back

SQL语句之delete

Fork me on GitHub

允许转载, 但转载请注明出处

Date:2013-01-01

看上面的SQL语句。

以前一直不知道原来delete后面可以直接写table

如果我们想从两个表中删除

delete user from user,post where user.id=post.user_id; /*删除user表中的相应记录*/
delete user,post from user,post where user.id=post.user_id; /*删除user表和post中的相应记录*/

Support:mkdwiki