Summary

In today's lesson, you learned how to join one or more tables together to produce useful collections of data for use by your application programs. You saw how to use the different types of joins depending on your needs. Inner joins can be used to gather information from multiple tables or from one table by restricting the number of rows that appear in a result set using the information contained in another table.

Understanding these different types of joins helps you to understand the concepts of T-SQL. You will need this understanding before going on to tomorrow's lesson on sub-queries. Finally, I want to leave you with a few do's and don'ts pertaining to using joins:

DoDon't
Be careful when using multipart keysInclude tables in a join if you don't need them
Use meaningful table aliasesUse SELECT * in a query
Qualify all columns in your queries 
Use constructive table aliases and column names in self-joins 

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset