Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
srussell705
Starting Member
4 Posts |
Posted - 2011-05-03 : 12:43:24
|
I have about 100 jobs on prod server of which 60% are enabled = 1 I want to push over to my warm backup server all jobs that are enabled via :select DISTINCT name as job_name , job_id, date_modified , enabled FROM msdb..sysjobs where enabled = 1ORDER BY 4,3 Or some sort there of. Any ideas on how to push my customized list ? I could see setting a weekly job out of this where I set an additional criteria to date_modified. TIA |
|
srussell705
Starting Member
4 Posts |
Posted - 2011-08-01 : 11:19:07
|
I had to write the switch statement in a SMO app. I iterate through all the jobs on a server and flip them if Running to disabled and enable all disabled jobs. Yes this means that you have to keep the jobs PRUNED and clean. |
|
|
|
|
|