Problems modifying SQL Server maintenance plan

After successfully migrating to the new medicat server in May, I decided to modify some scheduled maintenance jobs. But I kep getting an error:

Error 14274: Cannot add, update, or delete a job (or its steps or schedules) that originated from an MSX server. The job was not saved

A quick google search located some good resources:
http://www.dotnetjunkies.com/WebLog/daveadamson/archive/2005/09/26/132938.aspx
I tried this, and indeed, the originating_server field had the server’s preproduction name. I updated the field with the production server name, and then the medicat maintenance plan disappeared from the list in Enterprise Admin.
As panic started mounting, I decided to delete the individual jobs, and recreated the maintenance plan. I continued reading and found
http://www.karaszi.com/SQLServer/info_change_server_name.asp
It occurs to me that the datatype of the originating_server might not be a simple string, so I have executed the code sample:
DECLARE @srv sysname
SET @srv = CAST(SERVERPROPERTY('ServerName') AS sysname)
UPDATE sysjobs SET originating_server = @srv

I will check the maintenance logs tomorrow to make sure things have run correctly.

Leave a Reply