表间查询

  select positionChild,(select Remark from Freqs a join Contents b on a.ID=b.senior where b.ID=c.id) as senior,
  (select Remark from Freqs a join Contents b on a.ID=b.middle where b.ID=c.id ) as middle,
  (select Remark from Freqs a join Contents b on a.ID=b.general where b.ID=c.id ) as general
    from Contents c

posted on 2014-11-14 17:31  xihong  阅读(157)  评论(0编辑  收藏  举报

导航