I have a table that has many indexes.
One of these indexes is a complex expression using a function. I receive an error parsing the index expression.
I have bypassed this by using the loadIndices=false parameter but would like to enable indexes to speed up performance.
I am using VFP 9, SP 2. Here are examples of index expressions I have tried that all failed:
INDEX ON INVNUMBER("I") TAG invnumber && Where invnumber is a function. I have included invnumber.prg and invnumber.fxp in the table directory.
INDEX ON IIF(TYPE("invoices.invnumber")="N",invoices.invnumber,0) TAG invnumber
INDEX ON IIF(VARTYPE(invoices.invnumber)="N",invoices.invnumber,0) TAG invnumber
INDEX ON EVALUATE('IIF(TYPE("invoices.invnumber")="N",invoices.invnumber,0)') TAG invnumber
Hope you can help because your product looks good apart from this.
|
Continuing on from my previous email, I have discovered in your documentation the list of functions supported and you do not support a critical foxpro function which is TYPE and this is a standard XBASE function..
This function returns the type of an object being queried or "U" if undefined. We require this because we have expressions in our indexes that refer to functions in our application and these will be undefined when using the JDBC to query the data and will hence cause errors.
As you can see below, you also do not support VARTYPE or EVALUATE which are VFP specific functions and there is no other VFP function we can use to make our indexes work as we need and be compatible with HXTT.
Similarly, your JDBC driver should read any functions (FXP files) from the table directory directly to support other complex index expressions.
In the example below, we have INVNUMBER.FXP and INVNUMBER.PRG existing in the table directory but this is being ignored.
How can we get around this problem?
Hope you can assist.
Cheers
David Younger
--------------------------------------------------------------------------
I have a table that has many indexes.
One of these indexes is a complex expression using a function. I receive an error parsing the index expression.
I have bypassed this by using the loadIndices=false parameter but would like to enable indexes to speed up performance.
I am using VFP 9, SP 2. Here are examples of index expressions I have tried that all failed:
INDEX ON INVNUMBER("I") TAG invnumber && Where invnumber is a function. I have included invnumber.prg and invnumber.fxp in the table directory.
INDEX ON IIF(TYPE("invoices.invnumber")="N",invoices.invnumber,0) TAG invnumber
INDEX ON IIF(VARTYPE(invoices.invnumber)="N",invoices.invnumber,0) TAG invnumber
INDEX ON EVALUATE('IIF(TYPE("invoices.invnumber")="N",invoices.invnumber,0)') TAG invnumber
Hope you can help because your product looks good apart from this.
|
>In the example below, we have INVNUMBER.FXP and INVNUMBER.PRG existing in the
>table directory but this is being ignored.
>How can we get around this problem?
Extend SQL functions at here. HXTT DBF can't run Foxpro code since it's not a Foxpro runtime.
>I have bypassed this by using the loadIndices=false parameter but would like
>to enable indexes to speed up performance.
What's your sql which you want to run in Java code?
>you do not support a critical foxpro function which is TYPE and this is
>a standard XBASE function..
If those functions are critical for your project, we can complement it.
|