Linked server to a Sybase / SQLAnywhere database

Darrell Burns 141 Reputation points
2021-09-07T22:30:13.29+00:00

I've been beating my head against a wall trying to create a linked server to a SQLAnywhere 11 database from SQL Server (12.0). Can't seem to get the parameters right.
Since I can't seem to get my hands on a copy of SAOLEDB.12 I'm stuck using MSDASQL as the provider. But I can't get past this error message...

OLE DB provider "MSDASQL" for linked server "myserver" returned message "[Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified".

EXEC master.dbo.sp_addlinkedserver @Testta =N'MyServer'
,@srvproduct=N'SQL Anywhere'
,@provider=N'MSDASQL'
,@datasrc=N'SQLAnywhere64'
,@provstr=N'host=ServerName;dbn=DatabaseName'

ODBC System Data sources...

129987-datasources.png

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
12,759 questions
Transact-SQL
Transact-SQL
A Microsoft extension to the ANSI SQL language that includes procedural programming, local variables, and various support functions.
4,555 questions
0 comments No comments
{count} votes

6 answers

Sort by: Most helpful
  1. CathyJi-MSFT 21,096 Reputation points Microsoft Vendor
    2021-09-08T02:56:05.967+00:00

    Hi @Darrell Burns ,

    SQL Anywhere installation brings in ODBC drivers, both x32 bit and x64bit. Please using SQL Anywhere OLE DB Provider to create linked server. Under Server Objects node in SQL Server you can find Linked Servers with the providers that allows you to create linked servers as below screenshot.
    130015-screenshot-2021-09-08-105520.jpg

    If the SQL Anywhere OLE DB Provider did not exist in your environment , you can download drivers from below link.

    SAP SQL Anywhere Database Client Download

    Please also check if below blog could help you.

    Creating a linked server to SAP/Sybase SQL Anywhere 16 server in SQL Server 2012 Express


    If the response is helpful, please click "Accept Answer" and upvote it, as this could help other community members looking for similar thread.

    0 comments No comments

  2. Darrell Burns 141 Reputation points
    2021-09-09T20:40:43.683+00:00

    Hello Cathy. Yes, I already installed the Sybase Central management console for SQL Anywhere 12. I have installed the SQL Anywhere 12 driver, and created ODBC System DSNs for both 32- and 64-bit. What I can't find anywhere are the SAOLEDB providers. I've scoured the SAP site and the internet and haven't found a source. Do you know where I can download SAOLEDB 12?

    0 comments No comments

  3. CathyJi-MSFT 21,096 Reputation points Microsoft Vendor
    2021-09-10T06:56:38.7+00:00

    Hi @Darrell Burns ,

    Please check below link.

    https://wiki.scn.sap.com/wiki/display/SQLANY/SAP+SQL+Anywhere+Database+Client+Download


    If the response is helpful, please click "Accept Answer" and upvote it, as this could help other community members looking for similar thread.

    0 comments No comments

  4. Darrell Burns 141 Reputation points
    2021-09-10T12:52:55.217+00:00

    Yes, I downloaded and installed the SQL Anywhere client. It does not include the SAOLEDB provider.

    0 comments No comments

  5. CathyJi-MSFT 21,096 Reputation points Microsoft Vendor
    2021-09-13T07:32:49.55+00:00

    Hi @Darrell Burns ,

    Did you check that both x32 bit and x64bit SAOLED.12 are installed in your environment? Could you share us a screenshot about Providers from SSMS >Server Objects>Linked server >Providers in your environment?

    0 comments No comments