sys.sp_add_maintenance_plan
general #stored-procedure
Description
Adds a maintenance plan and returns the plan ID. This feature will be removed in a future version of SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature. Specifies the name of the maintenance plan to be added. Specifies the ID of the maintenance plan. This stored procedure is used with database maintenance plans.
Syntax
sp_add_maintenance_plan
[ @plan_name = ]
'plan_name'
, [ @plan_id = ]
'plan_id'
OUTPUT
[ ; ]
Examples
Example 1
EXECUTE
Example 2
sp_add_maintenance_plan
Example 3
EXECUTE sp_delete_maintenance_plan
'FAD6F2AB-3571-11D3-9D4A-00C04FB925FC'
;