MySQL Self Join

 

Self Join is designed to return rows with other rows within the same table. Table1 is joined with itself.

SELECT column_name1,column_name2,...
FROM table_name1 tab1, 
INNER JOIN table_name1 tab2 ON condition;

We are joining employees to their managers. You must use ALIAS for the table to distinguish the difference.

 




Subscribe To Our Newsletter
You will receive our latest post and tutorial.
Thank you for subscribing!

required
required


Leave a Reply

Your email address will not be published. Required fields are marked *