Data Analyst SQL Interview Question |Self-Joins Explained
ฝัง
- เผยแพร่เมื่อ 14 ต.ค. 2024
- Welcome to our deep dive into the world of SQL Self-Joins! 🌍🔍 In this tutorial, we unravel the intricacies of self-joins, a powerful SQL technique often surrounded by confusion. Whether you're a beginner trying to grasp the fundamentals or an intermediate looking to solidify your understanding, this video is tailored for you.
Making a note to come back to this
Thank you
I'm having a hard time understanding this one, is there another table with the managers name and the number of reports? Also, when you create e1 and e2 are these instances of the same table? Thx
Yes hence the self. You're joining the table with itself
Thank you for the clarification! @@ladhkay
Select e1.emp_name as employees_name, e2.emp_name as manager_name
From employee e1 join employee e2
On e1.manager_id = e2.emp_is
Ok
I know you’re trying to do a short video but just a little feedback to you. The people that search these kind of videos up are usually beginners so I would say when you’re explaining it I would explain it with a little more details. You kinda just brushed through the question
Em labham😂 ayipaye…