防止数据重复插入的触发器 事例:
create trigger manager_insert
on manager
instead of insert
as
begin
insert manager
select userID,password,rights,groupID,addtime from inserted k
where not exists(select * from manager where userID=k.userID)
end
防止数据重复插入的触发器 事例:
create trigger manager_insert
on manager
instead of insert
as
begin
insert manager
select userID,password,rights,groupID,addtime from inserted k
where not exists(select * from manager where userID=k.userID)
end
转载于:https://www.cnblogs.com/hellen-li/archive/2010/12/24/1916059.html