• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 658
  • Last Modified:

How do I link 2 sql server databases?

Hi

I have two servers both windows 2003 and running sql server 2005. Each server has one database in it and I would like to know how I get a link table (or something similar) on server1 to a table on server2 so that I can run views on server1 which will pull data from server2?

I've seen some info about sp_addlinkedserver but I don't know if that's what I want to use and if it is, how do I use it?

Thanks for any help you can give me.
Heather
0
ProfJames
Asked:
ProfJames
1 Solution
 
SireesCommented:
You should set up linked servers for this.

Check this link for more info

http://msdn2.microsoft.com/en-us/library/ms190479.aspx
0
 
NetstoreCommented:
The easiest way is to create the link in Enterprise Manager:

EM -> Security -> Linked Servers -> Right Click New Linked Server

Then just add the server name (ensure this server is visible through the network, e,g, telnet <target server> 1433). You will need a login to the target server.

Now you will be able to run sp's, pull data update the target server at you leisure.

Cheers
Si
0

Featured Post

Get free NFR key for Veeam Availability Suite 9.5

Veeam is happy to provide a free NFR license (1 year, 2 sockets) to all certified IT Pros. The license allows for the non-production use of Veeam Availability Suite v9.5 in your home lab, without any feature limitations. It works for both VMware and Hyper-V environments

Tackle projects and never again get stuck behind a technical roadblock.
Join Now