数据库可用于sql Server 2000& 2005年将在2008年使用链接服务器.
假设我在sql Server 2000中有一个名为LIVE_2000的数据库,在sql Server 2005中称为LIVE_2005,有人可以帮助我将LIVE_2000和LIVE_2005的链接服务器创建到sql Server 2008中?
第一件事是甚么可能的?
提前感谢…
解决方法
使用instructions on MSDN可以执行以下操作:
Click Start,click All Programs,click Microsoft sql Server 2005 or Microsoft sql Server 2008,and then click sql Server Management Studio.
In the Connect to Server dialog Box,specify the name of the appropriate sql Server,and then click Connect.
In sql Server Management Studio,double-click Server Objects,right-click Linked Servers,and then click New Linked Server.
In the New Linked Server dialog Box,on the General page,in Linked server,enter the full network name of the sql Serveryou want to link to.
Under Server type,click sql Server.
In the left pane of the New Linked Server dialog,under Select a page,choose Security.
You will need to map a local server login to a remote server login. On the right side of the Security page,click the Add button.
Under Local Login,select a local login account to connect to the remote server. Check Impersonate if the local login also exists on the remote server. Alternatively,if the local login will be mapped to a remote sql Server login you must supply the Remote User name and Remote Password for the remote server login.
In the left pane of the New Linked Server dialog,choose Server Options. Set the Rpc and Rpc Out parameters to True,and then click OK.
另一种方法是使用Transact sql编写查询以使用存储过程sp_addlinkedserver
设置服务器
EXEC sp_addlinkedserver @server='yourServer',@srvproduct='',@provider='sqlNCLI',@datasrc='yourServer\instance1';