Showing entries 1 to 1
Displaying posts with tag: left outer join (reset)
MySQL LEFT OUTER JOIN Tutorial & Examples

Here you find information about writing LEFT JOINs (also referred to as LEFT OUTER JOINs). This introduction into left joins includes a description, syntax information and example statements that use left outer joins. The Venn diagram on the left represents a result set that a statement with a left join produces. Please refer to the syntax examples below for an example. Links to additional information resources can be found at the end of this article.

Left Join syntax

First of all, some syntax examples for the impatient:

-- left join with USING-clause
SELECT *
FROM <leftTable> LEFT JOIN <rightTable>
USING(id)
-- left join with ON-clause
SELECT *
FROM <leftTable> a LEFT JOIN <rightTable> b
ON a.name = b.authorName

As you can see, a join condition can be written …

[Read more]
Showing entries 1 to 1