Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

SQL JOB takes too much time to execute Expand / Collapse
Author
Message
Posted Wednesday, January 08, 2014 11:52 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Monday, February 17, 2014 8:37 AM
Points: 19, Visits: 55
Hi,
I created one job, when execute it it takes around 9 hours and when i manually executes that sp which is used in job than only takes 1 min.

So why this happens ?

Please reply. it will be helpful,

Thanks in advanced.
Post #1529211
Posted Thursday, January 09, 2014 5:01 AM
Valued Member

Valued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued MemberValued Member

Group: General Forum Members
Last Login: Yesterday @ 4:40 AM
Points: 58, Visits: 310
read something about parameter sniffing.
put your code if its possible
Post #1529291
Posted Thursday, January 09, 2014 6:29 AM


SSCrazy

SSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazySSCrazy

Group: General Forum Members
Last Login: Yesterday @ 7:59 AM
Points: 2,078, Visits: 2,410
Is this problem reproducable? Does it occur when the job is scheduled to run at a different moment? Are other processes running at the same moment (could cause blocking issues)?


** Don't mistake the ‘stupidity of the crowd’ for the ‘wisdom of the group’! **
Post #1529313
Posted Thursday, January 09, 2014 10:12 AM


Ten Centuries

Ten CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen CenturiesTen Centuries

Group: General Forum Members
Last Login: Thursday, April 03, 2014 4:39 AM
Points: 1,098, Visits: 6,418
What time does the job run and what time are you testing your code?

Is anything else running when the job runs (scheduled)?
Post #1529444
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse