Over a million developers have joined DZone.

Understanding the Execution Plan [When Table JOIN Occurs Part-III]

DZone's Guide to

Understanding the Execution Plan [When Table JOIN Occurs Part-III]

· Database Zone ·
Free Resource

Running out of memory? Learn how Redis Enterprise enables large dataset analysis with the highest throughput and lowest latency while reducing costs over 75%! 


Continuing our journey here we see some others operators exist in our execution plan. Here is the query and Execution Plan that we are working from couple of weeks.

Example Query

SELECT e.JobTitle, a.City,
 p.LastName + ', ' + p.FirstNameASEmployeeName

FROM HumanResources.Employee AS e

 INNER JOIN Person.BusinessEntityAddress AS bea

ON e.BusinessEntityID =bea.BusinessEntityID

 INNER JOIN Person.Address a ON bea.AddressID =a.AddressID

 INNER JOIN Person.Person AS p
 ON e.BusinessEntityID = p.BusinessEntityID;

Execution Plan

Compute Scalar

First of all it is not a join operation. As it is covered in our Execution Plan, so we must discuss about it. Here we see the properties of the Compute Scalar.

It is represent a operation named Scalar, generally used for calculation purpose. In our case the alias Employeename = ContactLastname + Conatct.FirstName with comma operators between them. If we look at the property, it is not a 0 cost operators (0.001997).

If we look at the property Expr1008 and click at the ellipsis on the right side of the property page this will open the expression.

Related Reference

Understanding the Execution Plan [ When Table JOIN occurs Part-II ]


Understanding the Execution Plan [ When Table JOIN occurs Part-I ]


Understanding of Execution Plan – III - C [ The OPERATORS]


Understanding of Execution Plan – III - B [ The OPERATORS ]


Understanding of Execution Plan [What happened When SQL statement Execute]


Understanding of Execution Plan – II [Reuse of the Execution Plan]


Understanding of Execution Plan – III - A [ The OPERATORS ]



In the next level we have to more discuss about our execution plan. So this series will be continued for some more articles. Please be with us.

Hope you like it.

Running out of memory? Never run out of memory with Redis Enterprise databaseStart your free trial today.


Published at DZone with permission of

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}