Create a multi word search query

Boo

Registered User.
Local time
Today, 11:14
Joined
Aug 30, 2004
Messages
32
You guys are awsome!


Is there anyway to use Like in queries where the user could type in more than one word?


I have a text box (search title), on a form (Search).

On after update the text box, opens a query.

The criteria in the query for the Title field is:

Like "*" & [Forms]![Search]![search title] & "*"



this works great for one word or phrase.

I would like the user to be able to type in 2 words, and have the query find all the records where the first word is in the Title, and where the second word is in the Title. And so on with 3 words or more.
 
["Title] Like " & "*" & [Forms]![Search]![search title] & "*" _
" AND [Author] Like " & "*" & [Forms]![Search]![search author] & "*""

Just use AND and/or OR to concantenate other criteria.
 

Users who are viewing this thread

Back
Top Bottom