Operators describe how SQL Server executes a query or a Data Manipulation Language (DML) statement. The query optimizer uses operators to build a query plan to create the result specified in the query, or to perform the operation specified in the DML statement. The query plan is a tree consisting of physical operators. We can view the query plan by using the SET SHOWPLAN statements, the graphical execution plan options in SQL Server Management Studio, or the SQL Server Profiler ShowPlan event classes. Operators are classified as logical and physical operators. In the first exercise of this lab, we will explore different ways to view query execution plan. In the second exercise, we will look into different seek, scan and lookup operators. In the third exercise, we will look into a nested loop, merge and hash join operators and in the fourth and final exercise we will look into the stream and hash aggregate operators.
Exercise 1: Different Ways to View Query Execution Plan
Exercise 2: SEEK, SCAN and LOOKUP Show Plan Operators
Exercise 3: NESTED LOOP, MERGE and HASH JOIN Show Plan Operators
Exercise 4: STREAM and HASH Aggregate Show Plan Operators