dBASE Index files .MDX usage in VB 
Author Message
 dBASE Index files .MDX usage in VB

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 another Recordset that should use an .MDX index file with
a tag that is a composite key index: EMPNUM + Str(SHID).  The
code looks as follows:

  SQLStmt$ = "Select EMPSHIFT.ADATE From EMPSHIFT Where EMPNUM = '" _
              & gvGLB_UserID$ & "' And SHID = " & "Val(" & ShiftId$ &
");"
  Set rec_empshift = db_TKC.OpenRecordset(SQLStmt$, dbOpenSnapshot)

Do both SQL queries use the Index file tags to return records?  If my
syntax is wrong, than how can I make sure that the query is actually
using the indexes in the .MDX files.

Thanks,




Tue, 17 Nov 1998 03:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Using dBase files with MDX-indexes in Crystal reports

2. using DBASE-files with MDX-indexes in Crystal reports

3. Accessing existing dBase 5.0 Index files(mdx)

4. Using dbase MDX Files in VB Apps w/DAO

5. VB/Access and dBASE IV mdx files?

6. Dbase IV MDX Question

7. Problems using SQL and MDX-Index

8. *** .MDX Indexes used with SQL queries ***

9. Problems using SQL and MDX-Index

10. indexes in dBase 3 files?

11. I need to index dbase files in vb4 pro

12. Indexing a DBASE file

 

 
Powered by phpBB® Forum Software