Notice: This website is an unofficial Microsoft Knowledge Base (hereinafter KB) archive and is intended to provide a reliable access to deleted content from Microsoft KB. All KB articles are owned by Microsoft Corporation. Read full disclaimer for more details.

FIX: SQL Server Driver Fails to Connect over TCP/IP Using Three Parameters in Address Keyword


View products that this article applies to.

Symptoms

A connection to a back-end SQL Server database may fail, and you receive the following error message:
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]ConnectionOpen (Connect()).
[Microsoft][ODBC SQL Server Driver][TCP/IP Sockets]SQL Server does not exist or access denied.
This error occurs under the following conditions:
  • You are using the Microsoft ODBC Driver for SQL Server 2000 that comes with Microsoft Data Access Components (MDAC) version 2.6, 2.6 SP1, 2.6 SP2, or 2.7.
  • The TCP/IP protocol is used; in other words, the Network keyword is set to DBMSSOCN.
  • The Address keyword contains three parameters; for example, the server name or IP address, the port number, and an urgent token:
    "DSN=DSNName;SERVER=servername;DATABASE=pubs;Network=DBMSSOCN;Address=IP_Address,1433,urgent;"
    					
  • The server to which you are connecting is not a local server.
This article discusses one possible cause of this message. Applying the fix that is referenced in this article helps only if you experience this exact scenario. If you receive this message from Query Analyzer or SQL Enterprise Manager, you are not experiencing this particular scenario. This scenario only occurs when you pass an obsolete parameter at the end of a customer connection string.

↑ Back to the top


Cause

Beginning with MDAC 2.6, the SQL Server ODBC driver uses a "Super Socket" network library architecture which encapsulates all network libraries. If it finds three parameters in the Address keyword of a connection string, the Super Socket library assumes the SPX protocol instead of TCP/IP. (The SPX protocol is the only protocol that requires three parameters in the Address keyword; the TCP/IP protocol requires only two parameters. See the "More Information" section for details.)

↑ Back to the top


Resolution

A supported fix is now available from Microsoft, but it is only intended to correct the problem that is described in this article. Apply it only to computers that are experiencing this specific problem. This fix may receive additional testing. Therefore, if you are not severely affected by this problem, Microsoft recommends that you wait for the next MDAC service pack that contains this hotfix.

To resolve this problem immediately, contact Microsoft Product Support Services to obtain the fix. For a complete list of Microsoft Product Support Services phone numbers and information about support costs, visit the following Microsoft Web site:NOTE: In special cases, charges that are ordinarily incurred for support calls may be canceled if a Microsoft Support Professional determines that a specific update will resolve your problem. The typical support costs will apply to additional support questions and issues that do not qualify for the specific update in question.

IMPORTANT: Microsoft is releasing this fix for backward compatibility only. It is strongly recommended that you use the workaround described in the "Workaround" section instead of using this fix.

The English version of this fix should have the following file attributes or later:

MDAC 2.6, 2.6 SP1, and 2.6 SP2:
Date         Version            Size     File name     Platform
---------------------------------------------------------------
9-NOV-2001   2000.080.0467.00   86,097   Dbnetlib.dll  x86
				

↑ Back to the top


Workaround

To work around this problem, do not use three parameters in the Address keyword of the connection string when using TCP/IP. To connect to SQL Server over TCP/IP, only two parameters are needed: the server name or IP address, and the port number.

↑ Back to the top


Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.

↑ Back to the top


More information

Early Microsoft SQL Server 4.2 releases which first supported TCP/IP connections allowed an additional urgent parameter that changed the way that cancel requests were handled by the TCP/IP protocol stack. Later SQL Server 4.2 network libraries did not need the additional parameter and ignored it. The redesigned Super Socket network library does not take into account the use of this outdated additional parameter.

Note that using the urgent token does not affect a connection in any way. Prior to MDAC version 2.5, the urgent token was not used. Not using the urgent token did not cause any error and allowed the connection to occur.

For additional information on valid SQL Server connection string keywords, click the article number below to view the article in the Microsoft Knowledge Base:
229929 INFO: Registry Entries and Keywords for SQL Server Connection Strings

↑ Back to the top


Keywords: KB311836, kbqfe, kbprb, kbqfe, kbhotfixserver

↑ Back to the top

Article Info
Article ID : 311836
Revision : 9
Created on : 2/23/2007
Published on : 2/23/2007
Exists online : False
Views : 371