0
How to join tables
by using join claus
2 Réponses
+ 3
STUDENT(Id, Name, Surname, Age, UniversityId)
UNIVERSITY(Id, Name, City, Country, WorldRank)
Your boss want to know all Students' surname that belong to Pisa University. You must use Join cause the information is Split between the two table.
SELECT S.Surname
FROM Student S INNER JOIN University U ON S.UniversityId = U.id
WHERE U.City = "Pisa";
0
select s.surname from student s
inner join university u on s.id=u.id
where u.name='Pisa University'