eitanblumin.com
Control SQL Jobs based on HADR Role - Taking it to the Next Level - Eitan Blumin's blog
In one of my previous blog posts, Automatically Enable or Disable Jobs based on HADR Role, I provided a solution for managing scheduled jobs correctly in combination with Availability Groups and Database Mirroring. In this blog post, I'm going to build upon my previous solution and improve it even further - taking it to the next level of automation!
Eitan Blumin