求助 触发器禁止同时删除2行以上
这个是我的代码 提示 FROM 周围有错误 求解 谢谢了
CREATE TRIGGER TRI_NAME_DEL ON tblStudent FOR DELETE ASDECLARE @towcount intSET @towcount= COUNT(*) from DELETED if @towcount>2ROLLBACK TRANSACTIONprint 'you cannot delete more than one student at a time!'END
CREATE TRIGGER TRI_NAME_DEL ON tblStudent FOR DELETE asbeginDECLARE @towcount intselect @towcount= COUNT(*) from DELETED if @towcount>2begin ROLLBACK TRANSACTION print 'you cannot delete more than one student at a time!'endEND