put it in a proc then: sp_procoption @ProcName = 'ProcName', @OptionName = 'Startup',@OptionValue = 'True'