how to transulate mysql code in sql server
example :
select h1.name, h1.grade, h2.name, h2.grade
from (Highschooler as h1 join (select id1, id2 from likes join (select id2 as id1 ,id1 as id2 from likes) using (id1, id2))as a on h1.id=a.id1) join Highschooler as h2 on h2.id=a.id2 where h1.name < h2.name
↧