用Update Select批量更新某一字段的值[可以跨库]

SQL:

       update table1 set name = (select a.name from DB2.dbo.table2 a where test1.id = a.id)

你可能感兴趣的:(update,select,跨库,批量更新)