PRB: SQLBulkOperations Returns Function Sequence Error with Jet 4.0 ODBC Driver

Article translations Article translations
Article ID: 257517 - View products that this article applies to.
This article was previously published under Q257517
This article has been archived. It is offered "as is" and will no longer be updated.
Expand all | Collapse all

SYMPTOMS

With the Microsoft Jet 4.0 ODBC driver, a call to the SQLBulkOperations ODBC function, when preceded by a call to SQLExtendedFetch, may result in the following error:
DIAG [S1010] [Microsoft][ODBC Driver Manager] Function sequence error (0)

CAUSE

Earlier versions (3.5x) of the Jet ODBC drivers do not implement SQLBulkOperations. If an application uses this function with these versions, the ODBC Driver Manager changes the call to SQLSetPos, which does not produce this error when preceeded by SQLExtendedFetch.

Because version 4.0 of the Jet driver implements SQLBulkOperations, the call is not transformed by the Driver Manager. Instead, it is passed unchanged to the driver, which results in the error.

NOTE: The ODBC documentation expressly states that the combination of SQLExtendedFetch followed by SQLBulkOperations will result in a function sequence error.

RESOLUTION

Replace the SQLExtendedFetch call with a call to SQLFetchScroll.

Properties

Article ID: 257517 - Last Review: February 28, 2014 - Revision: 2.1
APPLIES TO
  • Microsoft Open Database Connectivity Driver for Access 4.0
  • Microsoft Data Access Components 2.1
  • Microsoft Data Access Components 2.5
Keywords: 
kbnosurvey kbarchive kbjet kbprb KB257517

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com