FoxPro 2.x Free Tables/Not using Index on Tables

FoxPro 2.x Free Tables/Not using Index on Tables

Post by Liza Sell » Fri, 28 Feb 2003 06:43:27



I am attempting to connect to foxpro free tables using ADO with the VFPOLEDB
provider.

The problem is everytime I do a SELECT * FROM [Tablename] WHERE [Criteria].
The query takes over 2 minues to run.  I don't think the connection is using
the Indexes specified on the table.

Does anyone know a way to force ADO connections to use a specific index on a
foxpro table?  Or a way to speed up this process?

I've tried using "SELECT * FROM [USE INDEXSEEK([index name]) [Table name]
WHERE [Critieria]

But this fails.  With ADO you get an '[USE INDEXSEEK([index name]).dbf' does
not exists.   I've also tried this same pass through technology with
DAO/ODBC connection and get "ODBC--call failed".  Any information will be
appreciated.

Thanks!
Liza

 
 
 

FoxPro 2.x Free Tables/Not using Index on Tables

Post by Cindy Winegarde » Sun, 02 Mar 2003 02:36:57


Hi Liza,

In order for the FoxPro indexes to "kick in" when you run your query the
expression you use in your WHERE clause must exactly match the index
expression. Do you know what the index expression is? Can you post the exact
query you are using?

[USE INDEXSEEK([index name]) is not a valid FoxPro construct which is why
you're getting errors.

--
Cindy Winegarden  MCSD, Microsoft Visual FoxPro MVP

http://mdsn.microsoft.com/vfoxpro  http://foxcentral.net


Quote:> I am attempting to connect to foxpro free tables using ADO with the
> VFPOLEDB
> provider.

> The problem is everytime I do a SELECT * FROM [Tablename] WHERE
> [Criteria].
> The query takes over 2 minues to run.  I don't think the connection is
> using
> the Indexes specified on the table.

> Does anyone know a way to force ADO connections to use a specific index on
> a
> foxpro table?  Or a way to speed up this process?

> I've tried using "SELECT * FROM [USE INDEXSEEK([index name]) [Table name]
> WHERE [Critieria]

> But this fails.  With ADO you get an '[USE INDEXSEEK([index name]).dbf'
> does
> not exists.   I've also tried this same pass through technology with
> DAO/ODBC connection and get "ODBC--call failed".  Any information will be
> appreciated.

> Thanks!
> Liza


 
 
 

1. FoxPro 2.x Free Table/Not using Index

I am attempting to connect to foxpro free tables using ADO with the VFPOLEDB
provider.

The problem is everytime I do a SELECT * FROM [Tablename] WHERE [Criteria].
The query takes over 2 minues to run.  I don't think the connection is using
the Indexes specified on the table.

Does anyone know a way to force ADO connections to use a specific index on a
foxpro table?  Or a way to speed up this process?

I've tried using "SELECT * FROM [USE INDEXSEEK([index name]) [Table name]
WHERE [Critieria]

But this fails.  With ADO you get an '[USE INDEXSEEK([index name]).dbf' does
not exists.   I've also tried this same pass through technology with
DAO/ODBC connection and get "ODBC--call failed".  Any information will be
appreciated.

Thanks!
Liza

2. Tradition Chinese Big5 in SQL server 7.0

3. BulkCopy from foxpro free table (*.dbf) to sql server table

4. Run-time error '429' cannot create ActiveX object

5. How to connect to FoxPro Free Tables using VB 6

6. Joyeux Noel

7. How to pack a FoxPro Free Table using ODBC

8. what is colstat 8192?

9. How to Pack a FoxPro Free Table using ODBC

10. Associating indexes with free tables using ODBC

11. Index not found! VB open FoxPro table

12. Index not found! VB open FoxPro 2.6 table

13. using FoxPro tables/indexes