create trigger TRG_MEMBER_DELETE ON member
instead of delete
as
begin
declare @sn int
set @sn = (select sn from deleted)
delete from member_join where fk_member in @sn
delete from member_visit where fk_member = @sn
delete from member where sn = @sn
end
--실행
delete from member where sn = 1
댓글 영역