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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 Compare efficiency of 2 SPs

Author  Topic 

Srinika
Master Smack Fu Yak Hacker

1378 Posts

Posted - 2006-09-20 : 09:24:30
Hi All,

Environment : SQL server 2k, Windows 2k
There was a Stored Procedure, in the DB I'm working which is farely inefficient. I modified that to make it efficient.

Now I want to see the difference in efficiencies, in terms of Speed, Memory Usage & CPU usage. How should I compare ?


Srinika

jsmith8858
Dr. Cross Join

7423 Posts

Posted - 2006-09-20 : 09:51:58
If they are not changing data (i.e., both are just returning rows) then just execute them one after another in the same QA batch. Then look at the Execution plans.


- Jeff
Go to Top of Page

Srinika
Master Smack Fu Yak Hacker

1378 Posts

Posted - 2006-09-20 : 10:22:56
Hi Jeff,

1. they do change data, so is that a problem (not as far as my data is concerned) if un in the way u suggest ? (means will it work ?)

2. I got the Execution Plan individually, but couldn't see a details as Speed, Memory Usage & CPU usage, instead it gives a diagramatic view on unknown stuff.

Srinika
Go to Top of Page

Srinika
Master Smack Fu Yak Hacker

1378 Posts

Posted - 2006-09-20 : 10:28:02
OK Thanks jeff,

I got it

Srinika
Go to Top of Page

Jim77
Constraint Violating Yak Guru

440 Posts

Posted - 2006-09-25 : 10:04:51
What was your solution with your question then Sri lanka ?
Go to Top of Page

Westley
Posting Yak Master

229 Posts

Posted - 2006-09-26 : 10:47:42
Can you keep those table out to another DB (all tables related to that stored proc), keep restoring it after each run, and run it a few times to get the avg with the old and new stored proc? Since its a backup of a smaller set of tables, it should be pretty fast and easy to restore.
Go to Top of Page

X002548
Not Just a Number

15586 Posts

Posted - 2006-09-26 : 13:17:18
Why wouldn't you start Profiler?



Brett

8-)

Hint: Want your questions answered fast? Follow the direction in this link
http://weblogs.sqlteam.com/brettk/archive/2005/05/25/5276.aspx

Add yourself!
http://www.frappr.com/sqlteam
Go to Top of Page
   

- Advertisement -