O'Reilly logo

Guru's Guide to SQL Server Architecture and Internals, The by Ken Henderson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Parsing

In order for a Transact-SQL query to be optimized by the SQL Server query optimizer, it must first be parsed into a tree of relational operators. These are the logical operators necessary to carry out the work the query has requested. For example, a simple query that joins the Northwind Customers and Orders tables might be parsed into a relational operator tree that includes an Inner Join logical operator between the two inputs.

SQL Server attempts to avoid redundantly parsing and optimizing queries by hashing the text of each newly submitted query and caching it in memory, along with the original query text and a link to the execution context and the execution plan that the original query resulted in. It checks the hashed query text ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required