SQL 练习3

  • 查询存在" 01 "课程,可能不存在" 02 "课程的情况(不存在时显示为 null )
SELECT * FROM (SELECT * FROM SC WHERE CID = '01') AS T1 LEFT JOIN (SELECT * FROM SC WHERE CID='02') AS T2 ON T1.SID = T2.SID

image

posted @ 2021-08-18 16:36  弩哥++  阅读(43)  评论(0编辑  收藏  举报