USP_SETDATABASESETUPCOMPLETED_RECORDOPERATION

Executes the "Database Setup: Set Complete" 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_SETDATABASESETUPCOMPLETED_RECORDOPERATION
(
    @ID uniqueidentifier,
    @CHANGEAGENTID uniqueidentifier
)
with execute as owner
as begin
    if (select value from fn_listextendedproperty(N'Hosting_DatabaseSetupCompleted', default, default, default, default, default, default)) is null
        exec sp_addextendedproperty @name = N'Hosting_DatabaseSetupCompleted', @value = 1
    else
        exec sp_updateextendedproperty @name = N'Hosting_DatabaseSetupCompleted', @value = 1

    return 0;

end