How To Force Query-Based Updates with ADO and MSDASQL (293658)
The information in this article applies to:
- ActiveX Data Objects (ADO) 2.5
- ActiveX Data Objects (ADO) 2.6
- ActiveX Data Objects (ADO) 2.7
- Microsoft OLE DB Provider for ODBC 2.0
- Microsoft Data Access Components 2.1
- Microsoft Data Access Components 2.1 (GA)
- Microsoft Data Access Components 2.1 SP1
- Microsoft Data Access Components 2.1 SP2
- Microsoft Data Access Components 2.5
- Microsoft Data Access Components 2.5 SP1
- Microsoft Data Access Components 2.6
- Microsoft Data Access Components 2.7
This article was previously published under Q293658 SUMMARY
When you use ActiveX Data Objects (ADO) with the Microsoft OLEDB Provider for ODBC Driver (MSDASQL), and you try to update a table using a server-side cursor, ADO uses positioned update by default. In this case, the MSDASQL provider calls the ODBC API SQLSetPos function with SQL_UPDATE to update the data. This may be a problem with some ODBC drivers that do not support SQLSetPos for particular cursor types.
This article demonstrates how to force ADO to do a query-based update with a server-side cursor.
NOTE: With client-side cursors, ADO always uses query-based updates.
Modification Type: | Minor | Last Reviewed: | 7/1/2004 |
---|
Keywords: | kbhowto KB293658 |
---|
|