EXEC master.dbo.sp_addlinkedserver
@server = 'your linked server name',
@srvproduct = '',
@provider = 'MSDASQL',
@provstr = 'DRIVER={SQL Server};SERVER=MyServer;UID=sa;PWD=sapwd;'
The above creates a default link to the Master Database on your desired server. Once Created go into the properties of the linked server and fill in the "Catalog" field to point to the database you want. 2
No comments:
Post a Comment