qry optimization

Last Post 24 Sep 2010 06:27 AM by gunneyk. 2 Replies.
AddThis - Bookmarking and Sharing Button
Author Messages
dbandee
New Member
New Member

--
22 Sep 2010 11:11 AM
i have a qry that runs 10 x slower when i add extra table (50 rows zipcode) to the join

so i mase two queries, the only diff in second one is taht extra join

what is the best way to compare the execution plans of these two queries

thanks
rm
New Member
New Member

--
23 Sep 2010 05:14 AM
Run both queries in same batch, sql will display plan and relative cost of each query.
gunneyk
New Member
New Member

--
24 Sep 2010 06:27 AM
I agree with rm that running them in the same batch is the best way to compare them side by side. I would also recommend turning on Statistics IO as well so you can compare the reads from each query as well.


Acceptable Use Policy
---