November 19, 2013 at 3:48 am
We are moving our databases to another server (both old and new server SQL Server 2008 v2). Is it possible to script (or export otherwise) the maintenance plans? I can't see the option, although it is obviously possible to script other jobs.
November 19, 2013 at 3:57 am
Type "move maintenance plans" into your favourite search engine. When I tried that, I got quite a few links that looked as if they were just what you're looking for.
John
November 19, 2013 at 9:23 am
Keeping in mind that maintenance plans are SSIS packages you could start here: Importing and Exporting Packages.
In SQL Server 2008 Your maintenance plans usually live in msdb.dbo.sysssispackage.
FYI: This will return a list of Maintenance plans:
SELECTf.foldername AS folder,
p.name,
p.description,
p.createdate
FROM msdb.dbo.sysssispackages p
CROSS APPLY
msdb.dbo.sysssispackagefolders f
WHERE f.foldername='Maintenance Plans'
AND p.folderid=f.folderid
-- Itzik Ben-Gan 2001
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply