SQL 更新(Update)聯合(join)的用法
update a --a是別名
set a.Field1=b.Field1 --設置的字段
from TB1 a --設置別名
left join TB2 b --聯合TB2表,並設置別名
on a.ID=b.ID --
where a.Field2 is null -- where的使用
方法僅供參考,請謹慎操作!
創建時間:2021.12.24 更新時間:
SQL 更新(Update)聯合(join)的用法
update a --a是別名
set a.Field1=b.Field1 --設置的字段
from TB1 a --設置別名
left join TB2 b --聯合TB2表,並設置別名
on a.ID=b.ID --
where a.Field2 is null -- where的使用
方法僅供參考,請謹慎操作!
創建時間:2021.12.24 更新時間:
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。