6

来源:互联网 发布:数据有效性在哪里 编辑:程序博客网 时间:2024/04/28 04:27

 句3:
      select  a.id as aid,
              a.value as av,
              b.id as bid,
              b.value as bv
      from table1 a
      left join table b on a.oid=b.oid
     
    执行结果如下:
      aid,  av,   bid,  bv
      1     101   1     201
      2     102   2     202
      3     103   3     203
      3     103   4     204
      4     104  
      5     105
      5     106