0.存储过程开头变量定义 ), --单据起始日期 ), --单据截止日期. ), ), ), ), ) @FType varchar(50), --单据类型@FBillNo varchar(50), --单据编号 1.日期范围查询 and t.FDate>=@FBeginDate and t.FDate<=case when @FEndDate='' then '2100-01-01' else @FEndDate end 2.客户代码范围查询 and t11.FNumber>=@FC
审核成功触发,是一个比较典型的场景.需要用到update触发器,跟踪到审核状态的变化. 引用的源码<采购检验单审核后反写收料通知单>,其中采购检验单是BOS自定义单据. if (object_id('bobang_tgr_check_update', 'TR') is not null) drop trigger bobang_tgr_check_update go create trigger cl_tgr_check_update on bobang_bos_check after upd