create trigger [dbo].[BBKZ] ON [dbo].[OUQR]
instead of update
AS
DECLARE @FirstTest VARCHAR(1000)
DECLARE @LastTest VARCHAR(1000)
SELECT @FirstTest=convert(varchar(1000),QString) FROM deleted
SELECT @LastTest= convert(varchar(1000),QString) FROM inserted
IF @FirstTest IS NOT NULL AND @LastTest =””
BEGIN
raiserror(‘ 不允许删除报表’,16,8)
rollback
END
发表回复