Assuming that: Dim RS As ADODB.RecordSet, why would the following statement change the performance of a VB program?
RS.Fields(“Customer”).Properties(“OPTIMIZE”) = True
...全文
941打赏收藏
又是一个硅谷招聘的VB数据库试题
Assuming that: Dim RS As ADODB.RecordSet, why would the following statement change the performance of a VB program? RS.Fields(“Customer”).Properties(“OPTIMIZE”) = True
An index can improve the performance of operations that find or sort values in a Recordset. The index is internal to ADO—you cannot explicitly access or use it in your application.
To create an index on a field, set the Optimize property to True. To delete the index, set this property to False.
Optimize is a dynamic property appended to the Field object Properties collection when the CursorLocation property is set to adUseClient.