级联删除
1,-- cascade,
2,with my1 as(select * from T_KM_Tree where kmid = @KMID
union all select T_KM_Tree.* from my1, T_KM_Tree where my1.kmid = T_KM_Tree.parentid)
delete from T_KM_Tree where exists (select kmid from my1 where my1.kmid = T_KM_Tree.kmid and my1.kmid!=@KMID);