Sql-server – SQL Server : Is it possible to have a linked server link to another linked server

linked-serversql serversql-server-2008-r2

Hello to all and thanks ahead of time for taking the time to look at my question!

I'm trying to do a work-around to access a 32bit Advantage Database Server 8.1 database with 64bit SQL Server 2008R2.

Setup:

  • Windows Server SBS2012
  • SQL Server 2008R2 64bit
  • SQL Server 2012 Express 32bit
  • Sybase Advantage Database Server (ADS) 8.1 32bit (can't change)

What I've done so far is to install a 32bit SQL Server Express on the same machine. I have setup a linked server to the Advantage database on that instance and successfully accessed data. So, I know that much is working fine.

Problem is, when I try to setup a linked server on the 64bit 2008R2 server, it errors out with the following…

OLE DB provider "SQLNCLI10" for linked server "[–MyLinkedServerName–]" returned message "Login timeout expired".
OLE DB provider "SQLNCLI10" for linked server "
[–MyLinkedServerName–]"
returned message "A network-related or instance-specific error has
occurred while establishing a connection to SQL Server. Server is not
found or not accessible. Check if instance name is correct and if SQL
Server is configured to allow remote connections. For more information see SQL Server Books Online.".
Msg 65535, Level 16, State 1, Line 0
SQL Server Network Interfaces: Error Locating Server/Instance Specified [xFFFFFFFF].

Like I said, I can access the data using the 32bit SQL Server Express, so I know that much of it works. I just can't seem to access it from within the 64bit 2008R2. I know the login info is correct.

So, Is it not possible to do?

Best Answer

I found my answer at MS SQL Server Forum: SQL Server 2005 X64 Linked Server error

Turnes out I had "Level zero only" checked

So, it goes something like this: x64 Query > Linked Server to x86 > View > Linked Server to ADS
So, something like this now works...

SELECT * FROM OPENQUERY([HAL2011\SQLEXPRESS], 'SELECT PartNum, OnHand FROM [master].[dbo].[vHPQoH]')

Where [HAL2011\SQLEXPRESS] is the x86 Server with a view [vHPQoH] to a lined server pointing to the Sybase ADS.

But thanks to everyone for your help. I still learned a lot! This place is great!