views:

145

answers:

3

Does anyone know of a tool that can be used to compare (relatively complex) query plans? I'm not looking for a guide to query plans, but just a tool that enables me to quickly see e.g. the different index use.

EDIT: just to make it clear, I'm not looking for information about the plan, but a tool that can quickly point out the differences between two plans (I know, I could do that myself, but the size of the plan(s) make that difficult).

+4  A: 

I'm not aware of a ready-made tool for this, just if you use SET SHOWPLAN_XML ON to get the plans in XML format you can pretty-format them in Visual Studio, and then compare with your favourite text comparison tool.

And you can also right click on the plan in SSMS and choose Save Execution Plan as... to save to a file.

devstuff
@devstuff: thanks - I'd sort of guessed that there was nothing out-of-the-box, but your suggestion seems like a good one.
davek
A: 

I generally just compare execution plans with a text compare tool - I also find that for complex plans its useful to look at the raw Xml of the plan just for the ability to search for an index / table to see where it appears in the plan.

Kragen
A: 

you can save them as XML files and ue XMLdiff to find the difference.

Dev