Oracle 中实现多表关联更新多个字段

网络整理 - 07-27

  update student A

  set (A.name,a.dq) =

  (select B.bname,b.bdq

  from newstudent B

  where B.Bid = A.id

  and A.dq = 10

  )

  where exists (select 1

  from newstudent B

  where B.Bid = A.id

  and A.dq = 10

  );