sp_addlinkedserver [@server =] "<server>"
[, [@srvproduct =] "<product name>"]
[, [@provider =] "<provider name>"]
[, [@datasrc =] "<data source path>"]
[, [@location =] "<location>"]
[, [@provstr =] "<connection string>"]
[, [@catalog =] "<database or equivalent for datasource>"]
EXEC sp_addlinkedserver @Server = "MyLocalServer",
@srvproduct = "SQLServer OLEDB Provider",
@provider = "SQLOLEDB",
@datasrc = "SOCRATES"
SELECT CustomerID, CompanyName
FROM MyLocalServer.Northwind.dbo.Customers
WHERE CustomerID < "1"