Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Adding wildcard automaticly
Message
From
29/06/2005 05:34:09
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
29/06/2005 05:20:39
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Environment versions
Visual FoxPro:
VFP 8 SP1
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01027298
Message ID:
01027302
Views:
12
This message has been marked as the solution to the initial question of the thread.
>I want to allow user to search by Wildcard, but he will not need to type the Wildcard and vfp will add it.
>For example:
ctext=thisform.txt1.value&&the user type 'xxx'
>select * from table where column1='%xxx%'&&vfp will run it with Wildcards.
select * from table where column1 like '%'+alltrim(thisform.text1.Value)+'%'

However in VFP this is case sensitive. Alternative:

select * from table where atc(alltrim(thisform.text1.Value)),column1) > 0

Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform