--创建触发器名称 CREATE trigger UserInfo_Role_delete --触发的表名 on UserInfo --删除 for delete as begin --触发后删除另一个表语句 delete R_UserInfo_Role where UserInfoID in (select id from deleted) End