ODBC Driver 17 for SQL Server with a 32-bit application in 64 bit OS doesn't seem to work

Resmi Jose 0 Reputation points
2024-07-08T23:16:36.1266667+00:00

I have a 32-bit application running in 64-bit OS. The application is connecting to SQL Server data base using the DSN created with ODBC driver "SQL Server" (SQLSRV32.DLL, version 10.00). But I have one customer who enabled TLS1.2 in their windows environment which requires the upgrade of the ODBC driver to latest versions. When I created the DSN using the latest version of ODBC drivers (tried version 13, 17 and 18), the connectivity test is not successful.

I get different errors time to time. Some of the error messages are below

 

Microsoft ODBC Driver for SQL Server Version 14.00.2037

 

Running connectivity tests...

 

Attempting connection

[Microsoft][ODBC Driver 13 for SQL Server]Named Pipes Provider: Could not open a connection to SQL Server [2].  

[Microsoft][ODBC Driver 13 for SQL Server]Login timeout expired

[Microsoft][ODBC Driver 13 for SQL Server]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.

 

TESTS FAILED!

 

It also a bit strange that the connection test works sometimes without any change. I think the basic issue is I'm creating a 32-bit DSN using "ODBC Data Source Administrator 32-bit" and using the ODBC driver 64 bit (which is what I can install in my 64-bit OS). If I use "ODBC Data Source Administrator 64-bit", everything works fine. But as my application is 32-bit I can't use this DSN.

Do I have any other option without migrating my application to 64-bit?

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
13,403 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. LiHongMSFT-4306 25,801 Reputation points
    2024-07-09T06:14:01.91+00:00

    Hi @Resmi Jose

    A network-related or instance-specific error has occurred while establishing a connection to SQL Server. Server is not found or not accessible.

    Regarding this connect issue, it is suggested to troubleshoot issue follow by this doc.

    Best regards,

    Cosmog Hong


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    0 comments No comments

  2. Erland Sommarskog 107.5K Reputation points MVP
    2024-07-09T08:20:41.6933333+00:00

    As Cosmog suggests, the error message means that you cannot reach the SQL Server instance you specified. This can be due to fat-fingering server and/or instance names, firewalls.

    I don't see there is very much relation to 32/64-bit here. Note that you can use the 32-bit ODBC driver on a 64-bit OS. You need to run the 64-bit install, but it will give you both.

    0 comments No comments