Left Join

  1. Using a left join, write a SQL query that returns all columns and rows from a tabled called “Employee”, and any matching rows in a table called “Phone”, where the phone table has a column called “EmployeeID” that is a foreign key to a column called “EmployeeID” in the employee table (do not use table aliases, e.g., “Phone AS p”):
    1. SELECT * FROM Employee LEFT JOIN Phone ON Phone.EmployeeID = Employee.EmployeeID
    2. SELECT * FROM Employee LEFT JOIN Phone ON Employee.EmployeeID = Phone.EmployeeID
      1. Any of the above are correct
  2. When using a left join, if there is not a matching row in the right table, what is returned for the unmatched columns in the right table? (a word that means the absence of value)
    1. NULL

Instructions: 

  1. Click the play button to watch the video lesson.
  2. Watch the lesson as many times as needed.
  3. Code along with the instructor using the integrated code editor in the center of your screen.
  4. You can use the Run button beneath the code editor to test your code.
  5. Output from the code that you have written will appear in the panel on the right side of your screen.

If you get stuck or need assistance, you can click the button below to connect with a tutor. 

For additional questions or technical support, email support@veroskills.com