Sql-server – The specified @job_id does not exist

sql serversql-server-agent

After deleting a SQL Server Agent job I continue to get notifications that the job attempted to run and failed. I am receiving the following error message.

[000] Unable to retrieve steps for job my_job
[298] SQLServer Error: 14262, The specified @job_id
('CC65FEFB-0033-442E-B55E-6209E25C5039') does not exist. [SQLSTATE
42000]

I have checked the following tables in the msdb database and none of them have the specified job_id except the dbo.sysjobhistory table.

  • dbo.sysjobs
  • dbo.sysjobschedules
  • dbo.sysjobsteps
  • dbo.sysjobstepslogs
  • dbo.sysjobservers
  • dbo.sysjobactivity
  • dbo.sysjobhistory

Is there anywhere else I can look?
Also, today I have stopped and restarted the SQL Server Agent and will update this post tomorrow with the result.

Thank you in advance!

Best Answer

A stop and start of the SQL Agent fixed the issue.