BUG: Wrong Rowset Size Returned by ODBC Driver Manager

ID: Q195080

The information in this article applies to:

SYMPTOMS

When the SQLGetStmtOption (in ODBC 2.x) or SQLGetStmtAttr API (in ODBC 3.0 or 3.6) is used to get the maximum rowset size with the ODBC 3.0 or 3.6 Driver Manager, the wrong value is returned. SQL State 01S02 is returned while the rowset size is specified initially.

CAUSE

The Driver Manager caches the initial value that was submitted as the rowset size. Instead of returning the corrected rowset size, the Driver Manager sends back the cached value.

STATUS

Microsoft has confirmed this to be a problem in the ODBC driver versions 2.x, 3.0, and 3.6.

MORE INFORMATION

According to the ODBC specifications, when the size of the rowset specified by the client exceeds the maximum permitted value for a data source, the driver substitutes the maximum permitted value as the rowset size and returns the SQL State 01S02. The SQLGetStmtOption (in ODBC 2.x) or SQLGetStmtAttr API (in ODBC 3.0 or 3.6) is used to get the rowset size. The ODBC 3.0 or 3.6 Driver Manager returns the wrong rowset size.

This problem has also been reproduced with the Microsoft Oracle driver Msorcl32.dll version 2.73.7356. All the other Microsoft ODBC drivers allow the rowset size to be equal to the maximum value for the data type used to store the rowsetsize.

Additional query words: max datatype row set datasource

Keywords          : kbODBC351bug odbcAPI odbcDrivermgr 
Version           : WINDOWS:2.x,3.0,3.6; WINNT:6.5
Platform          : WINDOWS winnt
Issue type        : kbbug
Solution Type     : kbpending

Last Reviewed: November 11, 1998