SQL FULL OUTER JOIN keyword is used to return all the rows from the left table (i.e., table1) and from the right table (i.e., table2).
Here is the general form of the FULL OUTER JOIN keyword in SQL:
SELECT column_name(s) FROM table1 FULL OUTER JOIN table2 ON table1.column_name=table2.column_name;
Let us assume that we have the following two table named "Admissions" and "Students".
Here is an example of FULL OUTER JOIN keyword in SQL. The following SQL statement selects all students having the same StudentId present in both the table (here we are going to query the sql statements which will display all the records) :
SELECT admissions.studentID, students.Name, admissions.AdmissionYear, students.address FROM students FULL OUTER JOIN admissions ON students.studentID=admissions.studentID ORDER BY students.Name;
After querying the above SQL Statements, you will get this output: