--ÎÞÏÞÊÔÓÃ if exists(select 1 from sysobjects where type='TR' and name='trgg_dmyp_type_delete') drop trigger trgg_dmyp_type_delete go create trigger trgg_dmyp_type_delete on dmyp_type for delete as begin if @@rowcount=0 return declare @date datetime select @date = getdate() update th_corp set CORP_DATETIME1 = @date update th_doc set DOC_JRHH = CONVERT(varchar(100), @date, 112) UPDATE bhsys..t_sys_zt SET rq_zt_creat = @date WHERE mc = 'KunMing_MeiKong' end go