Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using SQL "Like" from ASP(vbscript)

Status
Not open for further replies.
Feb 16, 2001
3
0
0
US
IIS 5.0 / MySQL v3.23.47
I have the following in an asp page on our Intranet:

SELECT * FROM photofile WHERE (LastName Like '%" & keyword & "%') order by LastName asc

With "keyword" being the name of the form field being posted.

This works 99.9% of the time. My users have found a couple of instances where it will not return the name(s) searched for.

Simpson does not work
Sim does work
pson does work
Simp does not work
imp does not work
Zito does not work
Z does work
Zi does work
Zit does not work
ito does not work

"i" seems to be the common denominator. If I do the same queries from mysql they all work correctly.

Any assistance/ideas would be GREATLY appreciated!

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top