Posted by : Anwar Hossain
Category : Basic sql tutorial for Beginner

FULL OUTER JOIN using two tables in SQL server

Dear viewer I will show to build FULL OUTER JOIN between two tables. By using The SQL FULL OUTER JOIN return all rows from left and right table in this case there is no need to match in the right and left table row. So we can say FULL OUTER JOIN means return all row from left table and right table and matched or unmatched row is returned from left right table and blank row is displayed as null.

FULL OUTER JOIN example in SQL server

Department Table

Department-table.png

Employee Table

Department-table.png

SQL Join Syntex

SELECT table1.column1,table1.column2,table2.column3
FROM table1
FULL OUTER JOIN table2
ON table1.common_column = table2.common_column;

SQL Statement

SELECT Department.DepartmentName,Employee.Name,
Employee.Email,Employee.PhoneNumber,Employee.Salary
FROM Department
FULL OUTER JOIN Employee
ON Department.ID = Employee.DepartmentId

SQL Statement Result

sql-fullouter-join



Realted Article Headline

How to use MIN () Aggregate Function
How to use MAX () Aggregate Function
How to use SUM () aggregate function
how to use AVG () aggregate function
How to use sql alies for sql table
SQL BETWEEN Operators for retrieving range values
FULL OUTER JOIN using two tables in SQL server
LEFT JOIN using two tables in SQL server
How to join two table in sql server

Article Category

How to create asp.net control dynamically
Learn HTML for beginner
DataList example in C Sharp
Mail sending in asp.net c#
State Management in ASP C #
Basic sql tutorial for Beginner
DataTable example in ASP.Net C#
How to use LINQ in ASP.NET C#
asp.net c # basic tutorial
How to use ajax toolkit in asp.net C#
How to use different types of validation control using asp.net c#
How to use grid view in asp.net c#
Protected by Copyscape Online Plagiarism Detection