how do i query characters in random order

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Ok, here is my dilemma.
I currently have a SQL statement that queried an EXCEL sheet which had
pricing and product descriptions from the head office.
Now i wish to make a query that aides the sales staff by searching the
description field. The problem with my SQL statement (which reads something
like:)

Where (field1) like "*" & [Enter Specs Here] & "*"

Now in this case, field1 which is sent by the head office does NOT follow
any conventions. So while half the fields have the description have "3 drw
BST" others have "3 draw bst" or "bst 3 drw".

I was wondering if anyone can help me structure a query so that when asked,
a user can type in a simple line and all fields which contain those values
are returned, even though those values may not neccessarily be in order... if
you get my drift lol. Think of it as a Google kinda query, if i didnt make
any sense up there.

Thanks in advance
 
You just string together multiple expressions:

Where (field1) like "*" & [Enter Spec1 Here] & "*" And
(field1) like "*" & [Enter Spec2 Here] & "*" And
(field1) like "*" & [Enter Spec3 Here] & "*" And
(field1) like "*" & [Enter Spec4 Here] & "*"
 
Back
Top