
*** .MDX Indexes used with SQL queries ***
Does VB 4.0 Use the Indexes from the .MDX index file for attached
DBF (dBASE IV) database files in SQL queries, which return
data in Recordsets.
My concern is that the Tables I am querying to return
records can be huge, and hence, the queries returning
records to my Recordset can take a long, long time.
Here is some of my VB code:
'*** DataDirname = "C:\KRONOS\TEM\DATA"
'*** ConnDBF = "dBASE IV; DATABASE=*.DBF;"
Set db_TKC = OpenDatabase(DataDirname, False, True, ConnDBF)
psched$ = Trim(rec_emp("psched"))
SQLStmt$ = "Select SCHSHIFT.* From SCHSHIFT Where PSCHED='" & psched$
& "';"
Set rec_schshift = db_TKC.OpenRecordset(SQLStmt$, dbOpenSnapshot)
**************
I have a SCHSHIFT.MDX file with the PSCHED field as a primary key TAG.
Does the OpenRecordset call use this index in the SQL query? If not
how can I get it to do so?
Thanks,