12.
select distinct s.sn, c.cn, tTemp.tn from sc
left join s on s.sno = sc.sno
left join c on c.cno = sc.cno
left join --课程慧指对应穗戚的前族配老师
(select t.dept, t.tn, tc.cno from tc
left join t on tc.tno = t.tno) as tcTemp on tcTemp.cno = sc.cno
where s.dept = tTemp.dept