Operation of the remote library ----- sql server in the case of the local library is not connected to the far remote library

- Create a linked server

- in front of all fixed ------ q: their casual play ----- 38.107.111.185: ip remote server

exec sp_addlinkedserver 'q', ' ', 'SQLOLEDB ', '38.107.111.185'

---------------------------------- q: their casual play ----- SA : remote database logins HH --------- Z @ 223: remote database password
exec sp_addlinkedsrvlogin 'q', 'false ', null, 'sa', 'xhz @ 123'

- Query Examples ---- q represents the name of the database server ---- hhzs representatives ----- [dbo] [com_Company] represents the table name
select * from q [hhzs] [ dbo] [com_Company]...

 

 

 

 

Do not see paying someone else, let me see who go on leisure

Guess you like

Origin www.cnblogs.com/BoKeYuan259/p/10945493.html