USP_SMARTQUERYINSTANCE_TOGGLEMOBILIZE

Executes the "Smart Query Instance: Toggle Mobilize" record operation.

Parameters

Parameter Parameter Type Mode Description
@ID uniqueidentifier IN Input parameter indicating the ID of the record being updated.
@CHANGEAGENTID uniqueidentifier IN Input parameter indicating the ID of the change agent invoking the update.

Definition

Copy


create procedure dbo.USP_SMARTQUERYINSTANCE_TOGGLEMOBILIZE
(
    @ID uniqueidentifier,
    @CHANGEAGENTID uniqueidentifier
)
as begin

    update dbo.SMARTQUERYINSTANCE set MOBILIZE = case MOBILIZE when 1 then 0 else 1 end,
        CHANGEDBYID = @CHANGEAGENTID,
        DATECHANGED = getdate()
    where ID = @ID;

    return 0;

end