Suppose if you have two tables Table_A and Table_B and you want join both tables on a particular column ‘column_1’ then following are the syntaxes:
Inner Join joins returns only the records in both tables where the condition met
SELECT column_name(s)
FROM Table_A
INNER JOIN Table_B
ON Table_A.column_1 = Table_B.column_1;
Left Join returns all the records of the left table and the records of another table where the condition met.
SELECT column_name(s)
FROM Table_A
LEFT JOIN Table_B
ON Table_A.column_1 = Table_B.column_1;
Right Join returns all the records of the right table and the records of another table where the condition met.
SELECT column_name(s)
FROM Table_A
RIGHT JOIN Table_B
ON Table_A.column_1 = Table_B.column_1;
You can learn SQL by signing up for SQL certification course by Intellipaat.