Locked lesson.
About this lesson
Learn how to use joins to create a query using information from more than one table.
Exercise files
Download this lesson’s related exercise files.
9.02 understanding-joins - Exercise.docx53.1 KB 9.02 understanding-joins - Exercise solution.docx
154.8 KB TechGurusTicketing23.accdb
908 KB TechGurusTicketing23 - Complete.accdb
912 KB
Quick reference
Understanding Joins
Joins tell Access which data to retrieve from linked tables. There are three types of joins: INNER, LEFT, and RIGHT.
When to use
We specify a join type when running queries using linked tables.
Instructions
- Open ‘qryTest’ from the navigation pane.
- Select ‘tblStatus’ and press Delete.
- Delete the criteria from ‘Priority’ and 'CustomerName'.
- From the Add Tables pane, select ‘tblTicketCompany’ and click Add Selected Tables.
- Drag the ‘Company’ field from ‘tblTicketCompany’ to the grid.
- From the Query Design tab, in the Results group, click Run.
- Switch to SQL View.
- Note that the default is INNER JOIN.
- From the Query Design tab, in the Results group, click Run.
This means that the value must exist in both tables for the record to be returned.
- Switch back to Design View.
- Double-click on the line that links the tables to open the Join Properties dialog box.
- Select Option 2 (LEFT JOIN)
- Run the Query.
This means that the value must exist in the left table for the record to be returned.
- Switch back to Design View.
- Double-click on the line that links the tables to open the Join Properties dialog box.
- Select Option 3 (RIGHT JOIN)
- Run the Query.
This means that the value must exist in the right table for the record to be returned.
Login to downloadLesson notes are only available for subscribers.