June 16, 2000 10:10 AM

Linked Servers

Rating: (0)
SQL Server Magazine
InstantDoc ID #8992
Query remote SQL Server and non-SQL Server databases as if they were local
Linked servers are often-untapped resources that let you use distributed queries to query any server as if it were local. Distributed queries let you keep your inventory data in a DB2 database, for example, and your accounting data in a SQL Server database and query both sets of data as if they were in the same database, eliminating the cost and hassle of merging the two systems. SQL Server lets you execute such queries on any OLE DB-compliant data source. This article shows you how to set up, query, and gather meta data about linked servers.

...This article is for paid Professional Members only.

Already a Professional Member? Please log in now:

NOT A PROFESSIONAL MEMBER? YOU CHOOSE:

Professional Membership

Monthly

Annual

VIP Membership

Monthly

Annual

Add a Comment

for the person looking to see if a linked server exists, you can check the output of
sp_LinkedServers,

or you can do what the sp_linkedServers procedure does and run the following

select *
from master.dbo.sysservers
Where srvname = @YourLInkedServerName

Sage12/28/2006 5:04:35 AM


My shop recently installed a packed application which uses SQL Server 2000 as the database and UDB on AIX as the enterprise database to replicate data to and from. We use the Linked server with IBM OLE DB provider to access the enterprise data.

The vendor for the package application recommends us to enable "ALLOW INPROCESS" option on the linked server.

On the daily basis we run two batch jobs to upload and download (replicate) data between the two heterogenous databases. However, we are experiencing memory problem after a few runs of the batch jobs. The memory usage of the SQL server grows every time we run the batch and did not release it (the memory).

As a temporary solution, we have to stop and start the SQL server.

To us, it looks like a memory leaks, however Microsoft technical does not agree with it.

Do you have any hints or tips how to resolve it. Perhaps some option parameters that we have to check on or off ?

Thank you.

Regards,
T Tan
tantekh@manulife.com

Anonymous User 11/23/2004 2:55:29 PM


I have stored procedure that I am running in SQL Server 2000 that uses the OpenQuery(). This works great when I run it from SQL Server, but I try to execute it in a Visual Basic app using ADO and I get the following message:
[OLE/DB provider returned message: [Microsoft][ODBC driver for Oracle]Driver not capable].

I was wondering if anyone knew of a solution as to why this happens. Many thanks in advance.

Eddie

Anonymous User 11/17/2004 11:33:19 AM


I am using IBMDADB2 as well and the four part query was returning the same responses for me. It was only when I used openquery() that I was able to get results.

Anonymous User 11/4/2004 12:04:07 PM


I tried to create linked server to access in SQL sever using the steps outlined in this article. However, I keep getting the error 7339 message .
I tried to look up explanation for this error on the net and tried to resolve it based on the suggestions listed in those articles but with no success.
Also I tried to set up a linked server to dataware house its giving me err 7303, could not initialize the provider IBMDADB2, this comes if I use the provider IBM OLE DB Provider for DB2 servers, the DSN for datawarehouse has been set up using IBM DB2 ODBC DRIVER.
If I use MS OLE DB FOR ODBC DRIVER for datawarehouse than I get err 7399.
Can you please let me where I am going wrong. I have wasted a lot of time on this.
Your help is much appreciated
Nalina

Nalina 3/8/2004 8:02:05 PM


I can't find in this article how can i check if linked server already exist?
Thanks

Dmitry3/4/2004 9:01:51 AM


I have configured a linkedserver in SQL Server 2000 to a DB2 (AS/400) database using Microsoft's Oledb provider for DB2. I'm also using Host Integration Server with SP1 as my gateway. I can issue "select" statements through the server but "Inserts", "updates" and "deletes" do not work.

Can you help me with this?

Chris Singleton 10/10/2002 7:03:01 AM


I was wondering if it's possible to edit the values in a query of a LinkedServer?

Rick Bray 10/3/2001 9:52:32 AM


I have an Oracle 8i running on NT and the Select statement using the OPENQUERY method mentioned in your article (SELECT * FROM OPENQUERY(LINKEDSERVER, "SELECT * FROM northwind..Categories where CategoryName Like 'Sea%'")
does not work with quotation marks.

It works with a single quote but then I have trouble with the WHERE statement ( 'Sea%' )

Can you help me with this problem?

Jose Lucero
Real Property Technologies

Jose 7/24/2000 12:04:42 PM


You must log on before posting a comment.

Are you a new visitor? Register Here
GOOGLE LINKS
SPONSORED LINKS
FEATURED LINKS