Answered by:
SP & JOB performing very slow

Question
-
Hi team ,
Twodays back one of job was taken around 4 hours user is asking to me
find out the reasons can you any please suggest me
How can i find out this job & Sp Taken that much of time. please help me
Thanks in Advance
subuThursday, March 17, 2011 1:49 PM
Answers
-
Subu,
Try this links, should help you...
http://technet.microsoft.com/en-us/library/ms187874.aspx -> HOW TO
http://blog.sqlauthority.com/2007/12/22/sql-server-difference-between-index-rebuild-and-index-reorganize-explained-with-t-sql-script/ -> Diff between reorganize and rebuild of indexes
http://www.mssqltips.com/tip.asp?tip=1367 -> Scripts
One mroe thing, try some composed indexes like Table(Field1, Field2) if possible....
To improve performance in a proc to dom something:
1 - Declare every variable, table variable, temp table or any other thing that must be declared as the fist thing of proc
2 - If you are using a temp table to few values, change to variable tables (Don´t have I/O or statistcs what can generate recompile issue)
------------------------------------------------------------- Oracle OCA11g- Proposed as answer by WeiLin Qiao Tuesday, March 22, 2011 7:41 AM
- Marked as answer by WeiLin Qiao Saturday, March 26, 2011 10:54 AM
Thursday, March 17, 2011 2:44 PM
All replies
-
Subu,
2 days ago? i don´t think its possible, but, must have something in the job history....try the sql logs to....
------------------------------------------------------------- Oracle OCA11gThursday, March 17, 2011 2:06 PM -
Hi Team,
i have 4 stored procedures i have to check the performance right
1. update stastics
can you please suggest how can check the indexes position.
In which situvastion we have re-build indexes.
subuThursday, March 17, 2011 2:39 PM -
Subu,
Try this links, should help you...
http://technet.microsoft.com/en-us/library/ms187874.aspx -> HOW TO
http://blog.sqlauthority.com/2007/12/22/sql-server-difference-between-index-rebuild-and-index-reorganize-explained-with-t-sql-script/ -> Diff between reorganize and rebuild of indexes
http://www.mssqltips.com/tip.asp?tip=1367 -> Scripts
One mroe thing, try some composed indexes like Table(Field1, Field2) if possible....
To improve performance in a proc to dom something:
1 - Declare every variable, table variable, temp table or any other thing that must be declared as the fist thing of proc
2 - If you are using a temp table to few values, change to variable tables (Don´t have I/O or statistcs what can generate recompile issue)
------------------------------------------------------------- Oracle OCA11g- Proposed as answer by WeiLin Qiao Tuesday, March 22, 2011 7:41 AM
- Marked as answer by WeiLin Qiao Saturday, March 26, 2011 10:54 AM
Thursday, March 17, 2011 2:44 PM