Microsoft KB Archive/939965

= FIX: The SQL Server process may generate an access error violation when you use the OLE DB provider for DB2 that is included in Host Integration Server 2004 together with SQL Server =

Article ID: 939965

Article Last Modified on 12/4/2007

-

APPLIES TO


 * Microsoft Host Integration Server 2004 Standard Edition
 * Microsoft Host Integration Server 2004 Enterprise Edition

-



SYMPTOMS
Consider the following scenario:
 * You use the Microsoft OLE DB provider for DB2 that is included in Microsoft Host Integration Server 2004 together with Microsoft SQL Server.
 * The OLE DB provider for DB2 issues a query to obtain index keys from a computer that is running IBM DB2 for z/OS.
 * The computer that is running IBM DB2 for z/OS contains duplicate index names in the SYSIBM.SYSKEYS view.

In this scenario, the SQL Server process may generate an access violation error.

Note IBM DB2 for z/OS was previously known as IBM DB2/MVS.



CAUSE
This problem occurs because the OLE DB provider for DB2 does not include the following clause when the OLE DB provider for DB2 issues a query to obtain the index keys from the computer that is running IBM DB2 for z/OS:

SYSIBM.SYSKEYS.IXCREATOR = SYSIBM.SYSINDEXES.CREATOR

If the query causes the DB2 database to return duplicate index names, SQL Server generates an access violation error.



Hotfix information
A supported hotfix is now available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem. This hotfix might receive additional testing. Therefore, if you are not severely affected by this problem, we recommend that you wait for the next service pack that contains this hotfix.

To resolve this problem, submit a request to Microsoft Online Customer Services to obtain the hotfix. To submit an online request to obtain the hotfix, visit the following Microsoft Web site:

http://go.microsoft.com/?linkid=6294451

Note If additional issues occur or 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 hotfix. To create a separate service request, visit the following Microsoft Web site:

http://support.microsoft.com/contactus/?ws=support

File information
The English version of this hotfix 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.



STATUS
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the &quot;Applies to&quot; section.



MORE INFORMATION
After you apply this update, the OLE DB provider for DB2 issues a query similar to the following to obtain index information from a system that is running IBM DB2 for z/OS. SELECT VARCHAR(RTRIM(T1.TBCREATOR), 128) as TABLE_QUALIFIER , VARCHAR(RTRIM(T1.TBNAME), 128) as TABLE_NAME , smallint( CASE WHEN T1.UNIQUERULE = 'U' THEN 1 ELSE 2 END) AS NON_UNIQUE , VARCHAR(RTRIM(T1.INDEXSPACE), 128) as INDEX_QUALIFIER , VARCHAR(RTRIM(T1.NAME), 128) as INDEX_NAME , T2.COLSEQ as SEQ_IN_INDEX , VARCHAR(RTRIM(T2.COLNAME), 128) as COLUMN_NAME , T2.ORDERING as COLLATION , T2.COLNO as ORDINAL_IN_BASE FROM SYSIBM.SYSINDEXES T1  , SYSIBM.SYSKEYS T2 WHERE SYSIBM.SYSKEYS.IXNAME = SYSIBM.SYSINDEXES.NAME AND SYSIBM.SYSKEYS.IXCREATOR = SYSIBM.SYSINDEXES.CREATOR Until you apply this update, the SYSIBM.SYSKEYS.IXCREATOR = SYSIBM.SYSINDEXES.CREATOR clause is not included in the query.

The following tables give examples of query results before and after you apply this update.

Query results before you apply the update

Query results after you apply the update

After you apply this update, the data that the OLE DB provider for DB2 returns to SQL Server lets SQL Server determine whether the index names are duplicates. SQL Server determines this based on the different values in the IXCREATOR column.

For more information about software update terminology, click the following article number to view the article in the Microsoft Knowledge Base:

824684 Description of the standard terminology that is used to describe Microsoft software updates

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

Keywords: kbfix kbqfe kbpubtypekc kbhotfixserver KB939965

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.