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: SQLBulkOperations Returns Function Sequence Error with Jet 4.0 ODBC Driver


View products that this article applies to.

This article was previously published under Q257517

↑ Back to the top


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)

↑ Back to the top


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.

↑ Back to the top


Resolution

Replace the SQLExtendedFetch call with a call to SQLFetchScroll.

↑ Back to the top


Keywords: KB257517, kbprb, kbjet

↑ Back to the top

Article Info
Article ID : 257517
Revision : 3
Created on : 9/16/2003
Published on : 9/16/2003
Exists online : False
Views : 492