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: Error message when you use the Microsoft OLE DB Provider for DB2 (DB2OLEDB) to connect to an IBM DB2 database that is running on a Linux-based server: "SQLSTATE: 42601, SQLCODE: -104"


View products that this article applies to.

Symptoms

Consider the following scenario. You use the Sample Query option in the Data Access Tool (DAT) to connect to an IBM DB2 database that is running on a Linux-based server. In this scenario, you receive an error message that resembles the following:
Could not connect to data source Data Source Name:
One or more errors occurred during processing of command.
An unexpected token "WHERE =BEGIN-OF-STATEMENT<values>" was found following "".
Expected tokens may include: "". SQLSTATE: 42601, SQLCODE: -104
An IBM DB2 database that is running on a Linux-based server may return one of the following server class strings during the Exchange Server Attributes negotiation:
  • QDB2/LINUX
  • QDB2/LINUX390
  • QDB2/LINUXIA64
  • QDB2/LINUXPPC
  • QDB2/LINUXPPC64
  • QDB2/LINUXZ64
Note The server class string that the database returns depends on the Linux operating system on which the IBM DB2 database is running.

You receive the error message because the Microsoft OLE DB Provider for DB2 (DB2OLEDB) does not recognize the server class strings. The OLE DB Provider for DB2 does not recognize the server class strings because the provider was not tested against the DB2 operating system environment.

The OLE DB Provider for DB2 is not officially supported for use with IBM DB2 databases that are running on Linux-based servers. The OLE DB Provider for DB2 supports the following IBM DB2 operating system environments:
  • IBM DB2 V7 and later versions for z/OS to support an SNA LU 6.2 or TCP/IP network connection
  • IBM DB2 for OS/400 V5R1, DB2 for i5/OS V5R3 and later versions to support an SNA LU 6.2 or TCP/IP network connection
  • IBM DB2 for Universal Database V8.1 and later versions for Windows and AIX operating systems to support a TCP/IP network connection
The supported IBM DB2 operating system environments and features are listed in the Installation Guide.htm file that is included with Microsoft Host Integration Server 2004.

↑ Back to the top


More information

The OLE DB Provider for DB2 has been updated to support IBM DB2 databases that are running on Linux-based servers. After you apply this feature, the OLE DB Provider for DB2 correctly recognizes the server class strings that are returned by DB2 databases that are running on Linux-based servers.

Microsoft Knowledge Base article 911174 also describes a similar software update to the OLE DB Provider for DB2. That software update adds support for IBM DB2 databases that are running on Sun Microsystems Solaris systems. For more information about the update in Microsoft Knowledge Base article 911174, click the following article number to view the article in the Microsoft Knowledge Base:
911174 Error message when you use Microsoft OLE DB Provider for DB2 (DB2OLEDB) to connect to an IBM DB2 database that is running on a Sun Microsystems Solaris system: "SQLSTATE 58004, SQLCODE -901"

Software update information

Host Integration Server 2004

A supported feature that modifies the default behavior of the product is available from Microsoft. However, this feature is intended to modify only the behavior that this article describes. Apply this feature only to systems that specifically require it. This feature might receive additional testing. Therefore, if the system is not severely affected by the lack of this feature, we recommend that you wait for the next software update that contains this feature.

If the feature is available for download, there is a "Hotfix download available" section at the top of this Knowledge Base article. If this section does not appear, contact Microsoft Customer Service and Support to obtain the feature.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific feature. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site: Note The "Hotfix download available" form displays the languages for which the feature is available. If you do not see your language, it is because the feature is not available for that language. The English version of this software update has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.
File nameFile versionFile sizeDateTimePlatformSP requirement
Db2oledb.dll6.0.2021.0487,93617-Mar-200600:34x86SP1
Db2oledb.hNot Applicable24,51617-Mar-200600:40Not ApplicableSP1
Ddmstr.dll6.0.2021.044,03217-Mar-200600:34x86SP1
Drdaresync.exe6.0.2021.0337,40817-Mar-200600:34x86SP1
Microsoft.hostintegration.dataaccesslibrary.dll6.0.2021.086,01617-Mar-200600:34x86SP1
Microsoft.hostintegration.dataaccesstool.exe6.0.2021.02,703,36017-Mar-200600:35x86SP1
Microsoft.hostintegration.msdb2client.dll6.0.2021.0114,68817-Mar-200600:34x86SP1
Mseidb2c.dll6.0.2021.071,68017-Mar-200600:34x86SP1
Mseidb2d.dll6.0.2021.0435,20017-Mar-200600:34x86SP1
Mseidrda.dll6.0.2021.0694,78417-Mar-200600:35x86SP1
Note Because of file dependencies, the most recent fix that contains these files may also contain additional files.

↑ Back to the top


Microsoft OLE DB Provider for DB2 1.0

A supported feature that modifies the default behavior of the product is available from Microsoft. However, this feature is intended to modify only the behavior that this article describes. Apply this feature only to systems that specifically require it. This feature might receive additional testing. Therefore, if the system is not severely affected by the lack of this feature, we recommend that you wait for the next software update that contains this feature.

If the feature is available for download, there is a "Hotfix download available" section at the top of this Knowledge Base article. If this section does not appear, contact Microsoft Customer Service and Support to obtain the feature.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific feature. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft Web site: Note The "Hotfix download available" form displays the languages for which the feature is available. If you do not see your language, it is because the feature is not available for that language. The English version of this software update has the file attributes (or later file attributes) that are listed in the following table. The dates and times for these files are listed in Coordinated Universal Time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time item in Control Panel.
32-bit (x86) version
File nameFile versionFile sizeDateTimePlatform
Db2oledb.dll7.0.2485.0507,39225-Feb-200601:38x86
Microsoft.hostintegration.dataaccesslibrary.dll7.0.2485.02,554,64027-Feb-200623:33x86
Microsoft.hostintegration.dataaccesstool.exe7.0.2485.0617,22427-Feb-200623:33x86
Mseidrda.dll7.0.2485.0765,44025-Feb-200601:39x86
64-bit (x64) version
File nameFile versionFile sizeDateTimePlatformService branch
Db2oledb.dll7.0.2485.0747,00825-Feb-200602:29x64Not Applicable
Microsoft.hostintegration.dataaccesslibrary.dll7.0.2485.02,550,54427-Feb-200623:04x64Not Applicable
Microsoft.hostintegration.dataaccesstool.exe7.0.2485.0613,12827-Feb-200623:04x64Not Applicable
Mseidrda.dll7.0.2485.01,332,73625-Feb-200602:29x64Not Applicable
Db2oledb.dll7.0.2485.0507,39225-Feb-200601:38x86SYSWOW
Mseidrda.dll7.0.2485.0765,44025-Feb-200601:39x86SYSWOW
Note Because of file dependencies, the most recent fix that contains these files may also contain additional files.

↑ Back to the top


Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, regarding the performance or reliability of these products.

↑ Back to the top


Keywords: KB919646, kbqfe, kbhotfixserver, kbfix, kbdb2oledb, kbhis2004, kbinfo, kbautohotfix

↑ Back to the top

Article Info
Article ID : 919646
Revision : 2
Created on : 10/9/2011
Published on : 10/9/2011
Exists online : False
Views : 370