Oracle update......where......子句

来源:互联网 发布:淘宝地址写错了怎么改 编辑:程序博客网 时间:2024/05/16 05:24

update MT_EQ_EQUIPALLOCATION
   set gdzch0 = (select distinct puborgcode ||
                                 substr(ygdzch, 6, length(ygdzch) - 5)
                   from mt_pb_org t1, MT_EQ_EQUIPALLOCATION t2
                  where t1.orgcode = t2.drycdm)
 where exists
 (select distinct puborgcode || substr(ygdzch, 6, length(ygdzch) - 5)
          from mt_pb_org t1, MT_EQ_EQUIPALLOCATION t2
         where t1.orgcode = t2.drycdm)

 

Oracle 的update......where......子句和Sql Server 是不一样的