August 16, 2019 at 2:30 pm
Why would a scheduled job run much longer than just the code with running it in query builder the codes are identical
August 16, 2019 at 2:43 pm
There was similar question recently, take a look:
https://www.sqlservercentral.com/forums/topic/job-duration-much-longer-than-step-durations
--Vadim R.
August 16, 2019 at 4:02 pm
Actually this is more likely a problem of the 2 different ways of running the same query having different connection properties. I'd look there first. The most impacting setting is ARITHABORT
Here's a reference for the setting, Microsoft says explicitly in their documentation to always set ARITHABORT ON, setting it to OFF can negatively impact performance:
Yet the default for connections is usually set to OFF. You can change what the default setting is for connections that don't explicitly set them:
If you can confirm the connection already is using ARITHABORT ON, then it may be time to start looking into this article:
http://www.sommarskog.se/query-plan-mysteries.html
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply