Solved

How do I link 2 sql server databases?

Posted on 2006-10-30
3
634 Views
Last Modified: 2012-06-27
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
Comment
Question by:ProfJames
3 Comments
 
LVL 20

Expert Comment

by:Sirees
Comment Utility
You should set up linked servers for this.

Check this link for more info

http://msdn2.microsoft.com/en-us/library/ms190479.aspx
0
 
LVL 5

Accepted Solution

by:
Netstore earned 500 total points
Comment Utility
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

Zoho SalesIQ

Hassle-free live chat software re-imagined for business growth. 2 users, always free.

Join & Write a Comment

Introduced in Microsoft SQL Server 2005, the Copy Database Wizard (http://msdn.microsoft.com/en-us/library/ms188664.aspx) is useful in copying databases and associated objects between SQL instances; therefore, it is a good migration and upgrade tool…
Ever needed a SQL 2008 Database replicated/mirrored/log shipped on another server but you can't take the downtime inflicted by initial snapshot or disconnect while T-logs are restored or mirror applied? You can use SQL Server Initialize from Backup…
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Viewers will learn how the fundamental information of how to create a table.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now