Introduction to Oracle SQL
Sara Billen
Instructor
LEFT OUTER JOINRIGHT OUTER JOINFULL OUTER JOIN
Returns matched rows only
Returns matched rows and left table's rows
Returns matched rows and right table's rows
Returns matched rows and both tables' rows

SELECT t.TrackId, t.Name, i.InvoiceId, i.Quantity
FROM Track t LEFT OUTER JOIN InvoiceLine i
USING (TrackId)


SELECT c.CustomerId, c.SupportRepId, e.FirstName, e.LastName, e.Title
FROM Customer c RIGHT OUTER JOIN Employee e
ON c.SupportRepId = EmployeeId


SELECT c.CustomerId, c.SupportRepId,e.FirstName, e.LastName, e.Title
FROM Customer c FULL OUTER JOIN Employee e
ON c.SupportRepId = EmployeeId

Introduction to Oracle SQL