Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Query not optimized. Is this VFP 9 SP1 bug?
Message
From
15/12/2005 12:46:24
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Query not optimized. Is this VFP 9 SP1 bug?
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP2
Miscellaneous
Thread ID:
01078356
Message ID:
01078356
Views:
47
I found that in VFP9 SP1 some queries which can use index will take extremely long time to run in big tables.

To reproduce:
CREATE CURSOR rid ( doktyyp c(1), dokumnr n(7))
INDEX ON doktyyp+STR(dokumnr,7) TAG t
SOURCEDOCUMENT = CREATEOBJECT('test')

SYS(3054,1)
SELECT * from rid WHERE  ;
  SOURCEDOCUMENT.DOKTYYP+STR(SOURCEDOCUMENT.DOKUMNR,7)= ;
    RID.DOKTYYP+STR(RID.DOKUMNR,7)

DEFINE CLASS test as Custom 
doktyyp=''
dokumnr=0
ENDDEFINE
Observed: Rushmore optimization level for intermediate result: none

Expected: Rushmore optimization level for intermediate result: partial

Note. Query
SELECT * from rid WHERE  ;
    RID.DOKTYYP+STR(RID.DOKUMNR,7)= ;
  SOURCEDOCUMENT.DOKTYYP+STR(SOURCEDOCUMENT.DOKUMNR,7)
produces expected result.

Is this VFP 9 SP1 bug ?
Andrus
Next
Reply
Map
View

Click here to load this message in the networking platform