Same Domain:
Exec sp_addlinkedserver ' PC087 ': Add Remote Server
Exec sp_dropserver ' instcancename ':D elete Remote Server
Sp_helpserver check already registed server at current
Example of function of stored procedure name/view name
sp_addlinkedserver registering a remote DB instance exec sp_addlinkedserver ' instancename '
sp_dropserver Deleting a remote DB instance exec sp_dropserver ' instancename '
sp_addlinkedsrvlogin registered Remote Instance login access account exec sp_addlinkedsrvlogin ' instancename ', NULL
Sp_droplinkedsrvlogin Delete Remote instance login access account EXEC sp_droplinkedsrvlogin ' instancename ', ' UserName '
Sp_helpserver an accessible instance of the current instance that is registered (that is, viewing an instance that has been registered with sp_addlinkedserver) sp_helpserver
sys.sysservers function with Sp_helpserver select * from Sys.sysservers
Sys.linked_logins viewing registered login access accounts (that is, viewing accounts registered with sp_addlinkedsrvlogin) SELECT * FROM Sys.linked_logins
Sys.remote_logins view registered Remote access account SELECT * from Sys.remote_logins
Different Domain:
Use [Tracks]
UPDATE [Tracks]. [dbo]. Shipment SET [Tracks]. [dbo]. Shipment.ispublic=tdss. [IsPublic]
From
(SELECT * from OpenDataSource (' SQLOLEDB ', ' Data source=ip Address; User Id=sa; Password=password '). [Loadtestmanagerui]. [dbo]. [Tripdetailforshipmentsearch])
As Tdss
INNER join [Tracks]. [dbo]. Shipment s on Tdss. Shipmentid=s.shipmentid
Select in SQL server-cross Instance in same domain and different domain