3

Is there something similar to MySQL's "explain select" functionality for MSSQL 2008? From MySQL's documentation:

•When you precede a SELECT statement with the keyword EXPLAIN, MySQL displays information from the optimizer about the query execution plan. That is, MySQL explains how it would process the SELECT, including information about how tables are joined and in which order. EXPLAIN EXTENDED can be used to provide additional information.

http://dev.mysql.com/doc/refman/5.1/en/explain.html

jftuga
  • 5,731
  • 4
  • 42
  • 51

2 Answers2

5

You're looking for one of the following commands:

SET SHOWPLAN_TEXT ON/OFF
SET SHOWPLAN_XML ON/OFF

SSMS also has features built into the GUI to display an estimated execution plan (but doesn't actually execute the query) as well as display the actual execution plan. They are separate options.

K. Brian Kelley
  • 9,034
  • 32
  • 33
0

Query Analyzer provides a nice interface for the 'Execution Plan'. Try searching for that.