Wednesday, March 28, 2012

Maintenance Plan error

I am trying to create a maintenance plan and I get the folling error.

"exception has been thrown by the target of an invocation (mscorlib)"

additional information

"cannot find folder \"maintenace plans"

how do I resolve this?

A quick search threw up this reference:

http://www.unixadmintalk.com/f46/cannot-find-folder-maintenance-plans-229087/

The relevant information is:

I found a solution
use msdb
Verify that the folder is missing:
exec sp_executesql N'exec [msdb].[dbo].[sp_dts_getfolder] @.P1, @.P2',N'@.P1
nvarchar(17),@.P2 uniqueidentifier',N'Maintenance
Plans','00000000-0000-0000-0000-000000000000'

Add the folder if missing:
exec sp_dts_addfolder '00000000-0000-0000-0000-000000000000','Maintenance
Plans','08AA12D5-8F98-4DAB-A4FC-980B150A5DC8'

|||

Thanks for your help.

I did what you suggested, but it didn't quite work

I found another post on the internet that did solve the problem. Thought you might be interested. Once I did this, I was able to get maintenace plans to work

Here is what another said:

I just had exactly the same problem as you describe.... obviously the folder with the id '08AA12D5-8F98-4DAB-A4FC-980B150A5DC8' was already in the according msdb table.... check it out:

SELECT * FROM msdb.dbo.sysdtspackagefolders90

you will see that the folderid exists but has (for whatever reason...) the wrong name, not 'Maintenance Plans'. You can repair this by just using this statement:

UPDATE msdb.dbo.sysdtspackagefolders90
SET foldername = 'Maintenance Plans'
WHERE folderid='08AA12D5-8F98-4DAB-A4FC-980B150A5DC8'

It worked for me perfectly fine... after that maintenance plans can be created again....

No comments:

Post a Comment