How to Make a Join Easier to Read using Table Aliases

By: Kris Wenzel   |   Updated: March 6, 2022  
Works With: 

I recently put together a lesson on  table aliases and multi-table joins. 

You’ll find that as you write more complicated joins, that the SQL can become harder to read, as you’ll need to qualify column with table names to avoid ambiguity.  To make you SQL more compact and more readable you can create table aliases.

Read More: SQL Joins – The Ultimate Guide >>

The aliases become a short-hand naming convention.  That way, instead of referring to Person.PersonPhone.BusinessEntityID we can create the alias PP for Person.PersonPhone and simply refer to the column as PP.BusinessEntityID.

You can learn more about this this video, it’s transcript follows: