Old Style Joins

SQL queries can generate output by joining two or more tables together using the LEFT JOIN, RIGHT JOIN, or INNER JOIN operators, but these are by no means the only ways of joining tables in SQL.

The following is an example of an "Old Style" join:

SELECT Client.Surname, Client.GivenNames,
Employee.Surname, Employee.GivenNames
FROM Client,Employee
WHERE Client.EmployeeID=Employee.EmployeeID

Note that this is exactly the same as:

SELECT Client.Surname, Client.GivenNames,
Employee.Surname, Employee.GivenNames
FROM Client INNER JOIN Employee
ON Client.EmployeeID=Employee.EmployeeID

Both queries will generate exactly the same execution plan, and there is no performance penalty for using an old style join.

Home About the Author Copyright © 2001 Adelle Hartley