Monday 17 December 2012

Warning about SQL Server Scheduled Tasks

I've had cause to create scheduled tasks on SQL Server in the past and in general it's a simple process, write a bit of T-SQL, test it, put it on a job and schedule it, not much can go wrong, right?

Well on occasion it does go wrong if you're logged into a SQL Server as 'domain_name\trevor.best' then that will be the name of the owner of the job, seems logical. What isn't logical is when you get an error stating that it cannot verify my user name when it's OK with me being logged in normally to create the job.

The workaround for this is to set the owner to a SQL Server user (e.g., sa).

The moral of the story is once you've set up a scheduled task, hang around to make sure it runs on schedule.

No comments:

Post a Comment