Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
String searches SQL
Message
General information
Forum:
Visual FoxPro
Category:
Other
Title:
String searches SQL
Miscellaneous
Thread ID:
00105029
Message ID:
00105029
Views:
103
what is the fastest method to search for strings contained within a field using SQL? For example, I currently use:

(SIMPLE EXAMPLE)

ownername field might contain -> HAROLD D. SMITHE
I want every record that contains the name "SMITH" in table1

I am doing this:

SELECT OWNERNAME from table1 ;
WHERE ownername like '%SMITH%'

I do have and index on the ownername field.

This takes quite sometime to get resultant data back on my 70,000 record table. Is there a more optimized way of doing string searches than the way I'm doing it?



Any suggestions appreciated.

Thanks

john.
Next
Reply
Map
View

Click here to load this message in the networking platform