SQL Server Maintenance Plan Help
I'm using SQL Server Maintenance and found a way to selectively turn on and off various features of the plan via it's associated job shown in Figure A. This can be handy for me because I can create multiple versions of the job and selectively turn parts of the plan on or off as needed--without going into the GUI interface for the maintenance plans.
However, if I should open the associated plan via the maintenance plan GUI and save it--even if absolutely no changes were made--it deletes all of my customization in the Set values tab of the job--as shown in Figure B. I ran a trace, shown in Listing C, the shows my job being replaced with vanilla values.
Does anyone know how to stop this annoying behavior that erases the values in the Set values tab? (Or alternately to add my values to the plan GUI so they get added to the SQL job when I hit save).
p.s. SQL Maintenance is definitely not my favorite. I'm a T-SQL guy at heart but the company I'm currently at wants to use SQL Maintenance Plans.
Figure A: Maintenance Plan Job with customized values
I ran a trace and found that the GUI was recreating a vanilla version of the job after I resaved it--deleting my original values:
Listing C: Job values get replaced/erased
EXEC msdb.dbo.sp_add_jobstep @job_id=N'a76facdb-d100-46a0-9b7a-4f0fab85178c', @step_name=N'Subplan_1', @step_id=1, @subsystem=N'SSIS', @command=N'/Server "$(ESCAPE_NONE(SRVR))" /SQL "Maintenance Plans\Nightly Maintenance" /set "\Package\Subplan_1.Disable;false"'