Choosing the right backup solution for your organization can be a daunting task. To make the selection process easier, ask solution providers these 10 key questions.
ALTER TRIGGER [scheme].[metauddel] ON [scheme].[opheadm] AFTER UPDATE AS BEGIN -- SET NOCOUNT ON added to prevent extra result sets from -- interfering with SELECT statements. SET NOCOUNT ON; IF UPDATE (status) declare @Status char(1) declare @OrderNo char (10) declare @OrderLineNo char(1) declare @DateEntered datetime declare @Exist float select @Status = [status]from inserted with (NOLOCK) select @OrderNo = order_no from inserted with (NOLOCK) select @DateEntered = date_entered from inserted with (NOLOCK) if @Status = 9 Begin Insert into opdetm_audit (order_no,order_line_no,line_type,order_line_status,order_qty,despatched_qty,allocated_qty,val) Select order_no, order_line_no, line_type, order_line_status, order_qty, despatched_qty, allocated_qty, val from [scheme].[opdetm]with (NOLOCK) where order_no = @OrderNo and @DateEntered < CAST(FLOOR(CAST(GETDATE() AS FLOAT))AS DATETIME) End END
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.