I have a VB app that I use to correct records on an Rdb database on a VAX. I am using Microsoft’s TCP/IP and DEC’sODBC drivers. Our databases can get VERY large (in thehundreds of thousands to millions). I create a Dynaset ofan entire table and start at the beginning. Almost none ofmy users will begin their editing process there – they needa means to launch to the record they want. It seems thatFindFirst is much too slow (a few hours) to ever be useful.I’d like to make use of the indexes, but it seems I can’tcreate Table objects with ODBC, so “Seek” appears to be unavailable as an option. My solution thus far has beento create only dynasets of one record. This is still tooslow. Is there a better way to get to my records? I’ve readjust about everything I can get my hands on.
A couple of notes that are fairly obvious to you: Dynasets are slower than snapshots, since they have to create a connection to the database. Also, the ODBC is going to slow it down somewhat more, but it is negligible after the first operation.
What about providing your users with an intermediate search screen? It sounds like they know what they want to edit, they just have to get there. If you can narrow that million records down to a few thousand, things will run much better. As far as searching recordsets, you will probably have to do something like this:
dDm iFound as integeriFound = FalsedsData.MoveFirstDo While not dsData.EOF and not iFound iFound = dsData(field) = ‘criteria’ if not iFound then dsData.MoveNextLoopThis is reliable for searching dynasets and snapshots.