Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Partial Searching
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9
OS:
Windows XP SP1
Network:
Windows 2000 Server
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01107859
Message ID:
01107862
Views:
23
>I have a field on a form which will allow the user to search for any records by country. Therefore the user can type in +Ukraine +China. Just like on a search engine. The search is no problem I just dont know how to extract the Ukraine and China from their input prior to searching. Another example could be:
>
>+China +Morocco +Turkey
>
>I basically I want to extract n countries from the textbox (anything with a + sign denotes something to search on. Once I have these I can then use them as inputs into my SQL search.
>
>Thanks
m1 = [+China +Morocco +Turkey]
? ALINES(aaa,m1,1+4+8,[+])
It can't works if you put something like:
m1 = [China Morocco Turkey]
or
m1 = [China]

but this should works:
m1 = [+China +Morocco +Turkey]
m2 = [+]+CHRTRAN(m1,[ ],[+])
? ALINES(aaa,m2,1+4+8,[+])
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Reply
Map
View

Click here to load this message in the networking platform