Update Query with INNER JOIN between tables in 2 different databases on 1 server

后端 未结 11 1292
梦如初夏
梦如初夏 2020-12-08 09:29

Need some SQL syntax help :-)

Both databases are on the same server

db1 = DHE
db2 = DHE_Import

UPDATE DHE.dbo.tblAccounts 
INNER JOIN DHE_Import.dbo         


        
11条回答
  •  再見小時候
    2020-12-08 09:41

    Worked perfectly for me.

    UPDATE TABLE_A a INNER JOIN TABLE_B b ON a.col1 = b.col2 SET a.col_which_you_want_update = b.col_from_which_you_update;
    

提交回复
热议问题