Pages

Showing posts with label JOINS. Show all posts
Showing posts with label JOINS. Show all posts

14 August 2016

SQL - ADVANCED JOINS

In my earlier SQL- JOINS  post , I had discussed about INNER JOIN , LEFT OUTER JOIN, RIGHT OUTER JOIN, SELF JOIN and CROSS JOIN. In this post, I am going to discuss about ADVANCED JOINS. Please visit my earlier post on JOINS in below URL if you have not visited.

                               We have seen that LEFT OUTER JOIN includes matching rows between left table and right table and non matching rows from left table. This is illustrated with table and venn diagram as below:


                                                                                               
Select Name,Productname,Quantity,
       P.Productid,Mrp
From Customerinfo C
LEFT Outer Join Productinfo P
On C.Productid=P.Productid;