Recap On Some SQL and Joins: Bernie Lydon Bernie - Lydon@dbs - Ie
Recap On Some SQL and Joins: Bernie Lydon Bernie - Lydon@dbs - Ie
Bernie Lydon
Bernie.lydon@dbs.ie
What is SQL?
Now let us join these two tables using INNER JOIN as follows:
The SQL LEFT JOIN returns all rows from the left table,
even if there are no matches in the right table. This means
that if the ON clause matches 0 (zero) records in right
table, the join will still return a row in the result,but with
NULL in each column from right table.
This means that a left join returns all the values from the
left table, plus matched values from the right table or
NULL in case of no matching join predicate.
Now let us join these two tables using LEFT JOIN as follows:
This means that a right join returns all the values from the
right table, plus matched values from the left table or
NULL in case of no matching join predicate.
Now let us join these two tables using RIGHT JOIN as follows:
UPDATE Supplier_tbl
SET address1=‘Bray Business Park’, address2=‘Bray’
WHERE SupplierID=1;