Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Strtran() in SQL where clause
Message
From
28/08/2002 10:07:41
 
 
To
28/08/2002 09:18:23
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivia
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00694135
Message ID:
00694424
Views:
14
>>Hello,
>>
>>I have an SQL query where I need to use strtran() in the where clause:
>>WHERE STRTRAN(cname,' ','') = MyVar
>>
>>This slows down the process a lot!
>>Is it possible to optimize this query? I have alrdady an index on STRTRAN(cname,' ',''), but this does not change the performance.
>>
>>Any help is highly appreciated!
>
>An index on strtran(...) is virtually useless, since it is of variable length. Any decent VFP index has a fixed length. Perhaps padr(strtran(...)) will achieve better results.
>
>Hilmar.

Thanks, this is a good explanation for the reason why this index did not work. I did not know this!
Christian Isberner
Software Consultant
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform