Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP9 - SQL and Rushmore
Message
From
04/05/2015 13:09:53
 
 
To
04/05/2015 06:21:28
John Ryan
Captain-Cooker Appreciation Society
Taumata Whakatangi ..., New Zealand
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 8
Network:
Windows 2008 Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01619370
Message ID:
01619391
Views:
51
>>>The column DATEI is defined as C(240) and has an index on UPPER(DATEI).
>
>To use the index, you need the filter to be UPPER(datei) as well.
>
>
WHERE UPPER(Datei) = UPPER(lcPfad)
>
>With no index on Datei, a filter on Datei does a table scan.

That will force Rushmore to kick in, but still runs some unneccessary UPPER() calls following the btree.
local lcUpperPfad
lcUpperPfad =  UPPER(lcPfad)
SELECT Datei FROM ("DBCNAME!" + lcTabelle) ;
		WHERE UPPER(Datei) =  m.lcUpperPfad;
		INTO CURSOR TMP_DOKNAME
is somewhere between having good habits and premature optimization ;-))
Previous
Reply
Map
View

Click here to load this message in the networking platform