Want to improve this question? Add details and clarify the problem by editing this post.
Closed 8 years ago.
Improve this questionNeed to update a field with data from another field in a different database
I Have two SQL commercial Databases from the same company, the first Database has one field that is null in the o开发者_Go百科ther
I need to update the Field/Database that is null with the data of the first one.
MS SQL Server
Update table1 in current database from table1 in database called "DataBaseName"
update table1
set col2 = T2.col2
from DataBaseName.dbo.table1 as T2
where table1.ID = T2.ID and
table1.col2 is null
精彩评论