Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

How to search for more than one word?

Posted on 2004-08-27
5
Medium Priority
?
166 Views
Last Modified: 2013-12-24
I created a search form for our chamber of commerce at www.sodachamber.com which works with one word searches. How do I make it work with more than one word or just part of the words visitors type in?
  Are there any good online tutorials or books that teach detailed ASP database programming with FrontPage 2003?
0
Comment
Question by:annyearsley
  • 3
  • 2
5 Comments
 
LVL 12

Expert Comment

by:rcmb
ID: 11924146
Is the search searching the entire site or a database?
0
 

Author Comment

by:annyearsley
ID: 11924597
Just the database. I am using Atomz as a entire site search.
0
 
LVL 12

Expert Comment

by:rcmb
ID: 11925715
In your SQL statement all you need to do is have the statement read WHERE SearchField LIKE '%::FieldName::%'

This is a contains statement which will find the following:

If you enter the word "at" it would return

Bat
Hat
Attic
What
Cathy

Try this and let me know how it works for you.

RCMB
0
 

Author Comment

by:annyearsley
ID: 11927574
Yes, it does work that way. It will pick part of any word out but won't work if you type in two words, even if one word matches. Thanks!
0
 
LVL 12

Accepted Solution

by:
rcmb earned 500 total points
ID: 11927714
If you desire to search for two words then put in a second text box on your search form and change your query to look like:

WHERE (SearchField1 LIKE '%::FieldName::%' OR SearchField2 LIKE '%::FieldName::%')

Otherwise we are going to have to get away from frontpage wizards and use VBScript to write the code.

RCMB
0

Featured Post

[Webinar] Cloud and Mobile-First Strategy

Maybe you’ve fully adopted the cloud since the beginning. Or maybe you started with on-prem resources but are pursuing a “cloud and mobile first” strategy. Getting to that end state has its challenges. Discover how to build out a 100% cloud and mobile IT strategy in this webinar.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Now that Expression Web 4.0 (http://www.microsoft.com/expression/products/Upgrade.aspx) is free if you buy or have the full version of Expression Web 3.0, now is the best time to  migrate from FrontPage to Expression Web (http://www.frontpage-to-exp…
Geo-targeting is the practice of distributing content based on a person’s location, as best as you can determine it. Let’s look at some ways you could successfully use this tactic. The following tips and case studies could lead to meaningful results.
The purpose of this video is to demonstrate how to set up an RSS Feed on a WordPress Website. This will be demonstrated using a Windows 8 PC. Feedburner will be used for this demonstration. Go to your WordPress login page. This will look like the…
The purpose of this video is to demonstrate how to set up basic WordPress SEO. This will be demonstrated using a Windows 8 PC. The plugin used will be WordPress SEO by Yoast. Go to your WordPress login page. This will look like the following: myw…
Suggested Courses

885 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question