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.

PRB: DB2 Stored Procedures on OS390 Return Invalid Parameter Information


View products that this article applies to.

This article was previously published under Q291999

↑ Back to the top


Symptoms

When run against an IBM DB2 database that is installed on an OS390 server, ADODB.Commmand.Parameters.Count returns 0 when > 0 is expected. Any attempt to address elements of the parameters collection results in the following error message:
80040e51 Provider cannot derive parameter info.

↑ Back to the top


Cause

The requisite ODBC calls to determine parameter information (SQLDescribeParam and SQLNumParam) are equivalent to the OLEDB CImpICommandWithParameters::GetParameterInfo. Kagera uses both of these ODBC calls through its GetParameterInfo implementation. However, the available ODBC drivers for DB2 5.x support only the SQLNumParam call as version 5.x DRDA drivers (native/internal database drivers for DB/2) also did not support SQLDescribeParam. Therefore, calls to GetParameterInfo with DB2 5.x drivers result in the error DB_E_PARAMUNAVAILABLE which correctly indicates that Kagera was unable to implement GetParameterInfo.

↑ Back to the top


Resolution

SQLDescribeParam is supported in DRDA v 6.2 (IBM DB2 client software packages with version numbers 6.2 or newer).

Alternately, executing stored procedures through ADO against OS390 DB2 installations is successful provided that members and properties of the Parameters collection are not addressed explicitly.

↑ Back to the top


Keywords: KB291999, kbprb, kb3rdparty

↑ Back to the top

Article Info
Article ID : 291999
Revision : 4
Created on : 12/3/2003
Published on : 12/3/2003
Exists online : False
Views : 509